File tree 1 file changed +14
-1
lines changed
1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change 7
7
# Useful resources:
8
8
# * https://www.atlassian.com/git/tutorials/migrating-convert
9
9
# * http://www.janosgyerik.com/practical-tips-for-using-git-with-large-subversion-repositories/
10
+ # * https://github.com/varhub/git_status
10
11
#
11
12
# Clone command:
12
13
# $ git svn clone --stdlayout -A authors.txt <svn_url> <local name>
13
14
# - stdlayout is mandatory (see man for non canonical svn repos)
14
15
# - authors file must be complete
15
16
17
+
18
+ test -z " $( git status --short --porcelain) "
19
+ dirty=$?
20
+
16
21
set -e
17
22
18
- git stash && git svn rebase && git stash pop
23
+ if [ $dirty -gt 0 ]; then
24
+ echo " Found dirty workspace, stashing it..."
25
+ git stash --all --include-untracked
26
+ fi
27
+
28
+ git svn rebase
29
+
30
+ [ $dirty -gt 0 ] && git stash pop
31
+ echo " git SVN sync OK."
You can’t perform that action at this time.
0 commit comments