by JoshTriplett · 14y ago · 0 comments
Whenever I set up a new machine, I always do this:
git clone git://joshtriplett.org/git/home
mv home/.git .
rm -rf home
git checkout -f
(There probably exists a simpler way to do that, but I haven't found it yet.)I can always check out my repository via git:// even on a machine where I want to push to it, because my repository includes a ~/.gitconfig containing:
[url "ssh://joshtriplett.org/"]
pushInsteadOf = "git://joshtriplett.org/"
So, I can automatically push as long as I have SSH access to my server. (I wrote the support for pushInsteadOf in upstream git, specifically to enable this use case.) git init .
git remote add origin git://github.com/eentzel/dotfiles.git
git checkout -t origin master