Skip to content

Commit 1b30e1c

Browse files
author
victorar
committed
bin: update git-svn-push
1 parent b618b80 commit 1b30e1c

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

bin/git-svn-push

+14-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,19 @@
44
# Author: Victor Arribas <[email protected]>
55
# License: BSD-3-Clause <https://opensource.org/licenses/BSD-3-Clause>
66

7+
8+
test -z "$(git status --short --porcelain)"
9+
dirty=$?
10+
711
set -e
812

9-
git stash && git svn rebase && git svn dcommit && git stash pop
13+
if [ $dirty -gt 0 ]; then
14+
echo "Found dirty workspace, stashing it..."
15+
git stash --all --include-untracked
16+
fi
17+
18+
git svn rebase && git svn dcommit
19+
20+
[ $dirty -gt 0 ] && git stash pop
21+
echo "git SVN push OK."
22+

0 commit comments

Comments
 (0)