diff options
author | Patrick Spek <p.spek@tyil.nl> | 2023-03-08 08:58:33 +0100 |
---|---|---|
committer | Patrick Spek <p.spek@tyil.nl> | 2023-03-08 08:58:33 +0100 |
commit | e4a5cb6416a8908a65e274cd00f7ea04f5094d77 (patch) | |
tree | c1f2a303e1e9c7a8e31d218866bd745addc78b34 /lib/subcommands | |
parent | e777cbc1cb10da93cb257305b05a6bba54307813 (diff) |
Stash and pop changes when syncing
Diffstat (limited to 'lib/subcommands')
-rw-r--r-- | lib/subcommands/sync.bash | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/subcommands/sync.bash b/lib/subcommands/sync.bash index 0413ce4..ed03faa 100644 --- a/lib/subcommands/sync.bash +++ b/lib/subcommands/sync.bash @@ -17,8 +17,12 @@ subcommand() notice "bashtard/sync" "Syncing $BASHTARD_ETCDIR" pushd -- "$BASHTARD_ETCDIR" > /dev/null || return 4 + + git stash git pull origin master || return 4 git submodule update --recursive --remote || return 4 + git stash pop + popd > /dev/null || return 4 # Run a sync for each registered playbook for this host |