Re: Howto request: going home in the middle of something?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jan Wielemaker schrieb:
I've somewhere seen it in a mail, but I can't find it anymore. I have a
bare central (public) repository and clones on various machines I work
on. We all know it, you're right in the middle of something and it is
really time to go home. You want to pick up your work at home, but
without pushing to the shared repository.

I'm sure GIT can do this elegantly, but I'm not yet sure how.  I guess
Ideally I want "git stash" at work, transfer the stashed changes to my
other machine and apply them.  How do I do that?

One way is to use a bundle:

$ git checkout -b home
$ git bundle create home.bdl origin..home

Then put home.bdl on or USB stick or send by email. At home:

$ git fetch home.bdl home
$ git checkout -b to-be-continued FETCH_HEAD

You better make double sure that the commit "origin" that is used above is available at home.

Judge yourself whether this is "elegant".

-- Hannes
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux