From owner-freebsd-embedded@FreeBSD.ORG Sun Oct 6 20:31:02 2013 Return-Path: Delivered-To: embedded@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 9AF8A989 for ; Sun, 6 Oct 2013 20:31:02 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from mho-02-ewr.mailhop.org (mho-02-ewr.mailhop.org [204.13.248.72]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 7185A2E10 for ; Sun, 6 Oct 2013 20:30:58 +0000 (UTC) Received: from c-24-8-230-52.hsd1.co.comcast.net ([24.8.230.52] helo=damnhippie.dyndns.org) by mho-02-ewr.mailhop.org with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.72) (envelope-from ) id 1VSuyf-000Fcl-Rt; Sun, 06 Oct 2013 20:30:58 +0000 Received: from [172.22.42.240] (revolution.hippie.lan [172.22.42.240]) by damnhippie.dyndns.org (8.14.3/8.14.3) with ESMTP id r96KUtFP016566; Sun, 6 Oct 2013 14:30:55 -0600 (MDT) (envelope-from ian@FreeBSD.org) X-Mail-Handler: Dyn Standard SMTP by Dyn X-Originating-IP: 24.8.230.52 X-Report-Abuse-To: abuse@dyndns.com (see http://www.dyndns.com/services/sendlabs/outbound_abuse.html for abuse reporting information) X-MHO-User: U2FsdGVkX19QBWGOUlNpbnDa8O8Kf6eP Subject: Re: And experiment: Publishing my mercurial patch queue From: Ian Lepore To: Warner Losh In-Reply-To: References: Content-Type: text/plain; charset="us-ascii" Date: Sun, 06 Oct 2013 14:30:55 -0600 Message-ID: <1381091455.1152.58.camel@revolution.hippie.lan> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: embedded@FreeBSD.org X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Oct 2013 20:31:02 -0000 On Sun, 2013-10-06 at 13:21 -0600, Warner Losh wrote: > Greetings, > > With the code freeze, I'm starting to accumulate a few patches in my tree. I've started using mercurial to manage my patch queue after the utter fail of svn-stash to do what I want. Patch queues are a thing that hg has optimized for upstream submission, so publishing it seems a reasonable thing. > > If you don't have mercurial, or don't want to, you can look at the raw patch queue at this URL: > > http://people.freebsd.org/~imp/embedded-patch-queue/patches/ > > and brows the patches. All the files in this directory are patches, except series which lists the order. > > If you want to replicate what I have with mercurial: > > svn co > cd > hg init > hg add > hg forget .svn > cd .hg > hg clone http://people.freebsd.org/~imp/embedded-patch-queue/patches > cd .. > hg qpush, etc > > Anyway, thought I'd mention it here, since this may be a good way to get more involvement on my patches, some of which take months to fully bake due to the large range of mips and arm platforms we have. > > Comments? > You can speed up things like creating a new sandbox if you exclude .svn by default rather than adding it then forgetting it. I have in my .hgrc: [defaults] add = --exclude=.svn --exclude="glob:**.orig" status = --exclude=.svn and conversely in my .subversion/config I have: [Miscellany] global-ignores=.hg *.orig If you want to re-sync a svn+hg sandbox with -current, the incantations I've been using go like this... * hg commit any outstanding changes, or if they're not commitable yet use something like the hg attic extension to set them aside. In general, you want hg status to show a clean sandbox, including "unknown" files like .orig or ~ backups. * svn up * Now find everything svn up deleted and tell hg to delete it as well: hg status | grep "^!" | cut2 | xargs hg delete * Now tell hg to add new files added by svn up: hg status -u | grep "^?" | cut2 | xargs hg add * hg commit -m "Sync with svn rNNNNNNN" The "cut2" in those command sequences is this script: #!/bin/sh tr -s '\t ' ' ' | cut -d' ' -f2 -- Ian