Loading .shell/funcs +27 −0 Original line number Diff line number Diff line Loading @@ -60,6 +60,32 @@ get_shell() echo sh } update_submodules() { git stash git submodule init git submodule sync git submodule update git submodule foreach 'git checkout origin/` git config -f ~/.gitmodules submodule.${name}.auto-update 2>/dev/null || echo master`; cd $toplevel; git add $path' local updates="`git status --short -uno`" if [ -n "$updates" ]; then git commit -F- <<-END_MESSAGE Update submodules $updates Automatically generated: source: .shell/funcs:update_submodules() time: `date` host: `hostname -f` END_MESSAGE fi git stash pop } do_update() { local timestamp=${HOME}/.shell/.update Loading @@ -84,5 +110,6 @@ do_update() cd ~ git pull --ff-only origin update_submodules cd - >/dev/null } Loading
.shell/funcs +27 −0 Original line number Diff line number Diff line Loading @@ -60,6 +60,32 @@ get_shell() echo sh } update_submodules() { git stash git submodule init git submodule sync git submodule update git submodule foreach 'git checkout origin/` git config -f ~/.gitmodules submodule.${name}.auto-update 2>/dev/null || echo master`; cd $toplevel; git add $path' local updates="`git status --short -uno`" if [ -n "$updates" ]; then git commit -F- <<-END_MESSAGE Update submodules $updates Automatically generated: source: .shell/funcs:update_submodules() time: `date` host: `hostname -f` END_MESSAGE fi git stash pop } do_update() { local timestamp=${HOME}/.shell/.update Loading @@ -84,5 +110,6 @@ do_update() cd ~ git pull --ff-only origin update_submodules cd - >/dev/null }