From 0be68e89bd73e70978436463d8c8196d1770cf24 Mon Sep 17 00:00:00 2001 From: Jeff Fein-Worton Date: Sat, 22 Feb 2014 00:33:23 -0800 Subject: [PATCH 1/1] added sample post-init --- doc/sample_hooks/post-init-add-origin | 6 ++++++ doc/sample_hooks/post-init-setup-mr | 10 ++++++++++ 2 files changed, 16 insertions(+) create mode 100755 doc/sample_hooks/post-init-add-origin create mode 100755 doc/sample_hooks/post-init-setup-mr diff --git a/doc/sample_hooks/post-init-add-origin b/doc/sample_hooks/post-init-add-origin new file mode 100755 index 0000000..a3030d5 --- /dev/null +++ b/doc/sample_hooks/post-init-add-origin @@ -0,0 +1,6 @@ +#!/bin/sh + +# This adds a remote origin at $GITURL/dotfiles/$VCSH_DIRECTORY +# Assumes $GITURL is set to the base of your remote repos. + +vcsh $VCSH_DIRECTORY remote add origin $GITURL/dotfiles/$VCSH_DIRECTORY diff --git a/doc/sample_hooks/post-init-setup-mr b/doc/sample_hooks/post-init-setup-mr new file mode 100755 index 0000000..a38c012 --- /dev/null +++ b/doc/sample_hooks/post-init-setup-mr @@ -0,0 +1,10 @@ +#!/bin/sh + +# This sets up your new repos with mr. + +cat > $HOME/.config/mr/available.d/$VCSH_DIRECTORY.vcsh << EOF +[\$HOME/.config/vcsh/repo.d/$VCSH_DIRECTORY.git] +checkout = vcsh clone $GITURL/dotfiles/$VCSH_DIRECTORY.git +EOF + +ln -s $HOME/.config/mr/available.d/$VCSH_DIRECTORY.vcsh $HOME/.config/mr/config.d/ -- 2.39.5