From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bernt Hansen Subject: Re: org-mode tutorial questionaire Date: Wed, 24 Mar 2010 07:53:30 -0400 Message-ID: <87bpee0wcl.fsf@gollum.intra.norang.ca> References: <87bpeesu45.fsf@fastmail.fm> <87fx3q1mcv.fsf@gollum.intra.norang.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NuP9g-0005UF-Kv for emacs-orgmode@gnu.org; Wed, 24 Mar 2010 07:53:48 -0400 Received: from [140.186.70.92] (port=54692 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NuP9f-0005Tt-1B for emacs-orgmode@gnu.org; Wed, 24 Mar 2010 07:53:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1NuP9a-0000x1-SQ for emacs-orgmode@gnu.org; Wed, 24 Mar 2010 07:53:46 -0400 Received: from mho-02-ewr.mailhop.org ([204.13.248.72]:50984) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NuP9a-0000ww-P6 for emacs-orgmode@gnu.org; Wed, 24 Mar 2010 07:53:42 -0400 In-Reply-To: (Richard Riley's message of "Wed\, 24 Mar 2010 07\:32\:08 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Richard Riley Cc: Richard Riley , emacs-orgmode@gnu.org Richard Riley writes: > Bernt Hansen writes: > >> Richard Riley writes: >> >> I keep my ~/.emacs -> ~/git/emacs/emacs.el and ~/git/emacs/custom.el >> files in a git repository (~/git/emacs) so I can commit changes to these >> files and add meaningful comments about the reason for the change in the >> commit message. This lets me easily experiment with changing half a >> dozen variables and not worrying about remembering the old values in >> case I want to go back. Git has the information and it's easy to >> restore the old values for any point in the git history. This also lets >> me synchronize variable changes to my laptop so my on-the-road org-mode >> setup is identical to my workstation. >> > > As a side note to this is for those not familiar with git, its pretty > simple to manage a remote git repo using ssh. When on the road or > dealing with multiple PCs around the "globe" (!) this can be priceless. > > I maintain my own "sparse" repo on my mail server machine. Whenever I > update my ~/.emacs.d/emacs-init.org file or my custom.el in the same dir > I push it to the remote shh repo too. Handy as to then sync my laptop or > the machine at work. > > Needless to say, all my org-files are in there too. > > The only thing that still taxes my pickled brain is when I need to > merge. The git terminology for fast forwards etc confuses me each and > every time ;) Hi Richard, I use a script for keeping my git repositories up to date on multiple machines. The source is posted here: http://doc.norang.ca/org-mode.html#git-sync This script makes a few assumptions about my repositories - All repositories have a remote 'norang' which is the bare repository I push to and fetch from - All repositories live in a known place (~/git for me) (I have subdirectories under ~/git for grouping repositories together and the script finds every repository by looking for the .git directory) You can change both of these locations at the top of the script. git-sync finds each repository on the system you run it from and synchronizes multiple branches in each repositories with the remote. It figures out if the branch can be moved (due to a fast-forward) and moves those refs automatically for all branches in the repository. The only time you need to manually do something is if you need a merge because you modified the same branch on two machines without pushing the changes to the bare repository. This works great for me (I keep over 30 repositories in sync with my laptop -- I thought I had 35 repositories I manage this way so just for fun I decided to count them and there are 73!). I don't need to think about what changed, I just hack and commit and run git-sync before I switch machines. Any branch that has been pushed to the remote will be synchronized by the script and local branches that exist only in the working repository are ignored. HTH, Bernt