From mboxrd@z Thu Jan 1 00:00:00 1970 From: Achim Gratz Subject: Makefile: switch to a specific Git branch before update Date: Sat, 14 Dec 2013 11:33:18 +0100 Message-ID: <87ppozafip.fsf@Rainer.invalid> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44168) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VrmXS-0008C8-77 for emacs-orgmode@gnu.org; Sat, 14 Dec 2013 05:33:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VrmXL-0000ZV-FJ for emacs-orgmode@gnu.org; Sat, 14 Dec 2013 05:33:38 -0500 Received: from plane.gmane.org ([80.91.229.3]:60549) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VrmXL-0000ZM-8d for emacs-orgmode@gnu.org; Sat, 14 Dec 2013 05:33:31 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1VrmXJ-0003Hs-AK for emacs-orgmode@gnu.org; Sat, 14 Dec 2013 11:33:29 +0100 Received: from pd9eb1bc7.dip0.t-ipconnect.de ([217.235.27.199]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 14 Dec 2013 11:33:29 +0100 Received: from Stromeko by pd9eb1bc7.dip0.t-ipconnect.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 14 Dec 2013 11:33:29 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org In a number of recent discussions it transpired that some people expect to automatically be switched to a specific Git branch when updating. I've added this as an option to the standard Makefile. Simply define GIT_BRANCH (either on the command line or in local.mk) to determine which branch you want to update. If this variable is left undefined, you stay on the current branch as before. So, this definition in local.mk GIT_BRANCH = master would have the update targets operate on the master branch, regardless of which branch was checked out before the update. You can still update a different branch by overriding that variable like make GIT_BRANCH=my_branch update in this case or just stay on your checked-out branch using make GIT_BRANCH= update if you wish. If you are working on several branches, I recommend to leave this definition out of local.mk however and just use the command line override when necessary. Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Samples for the Waldorf Blofeld: http://Synth.Stromeko.net/Downloads.html#BlofeldSamplesExtra