File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,13 @@ def convert(source_scm)
93
93
r . scm . checkout ( r , url )
94
94
end
95
95
96
+ # Sometimes svn conflicts occur leading to a silent `svn checkout` failure.
97
+ if source_scm . is_a? ( SvnAdapter ) && SvnAdapter . has_conflicts? ( url )
98
+ logger . info { "Working copy has svn conflicts. Cleaning and trying again..." }
99
+ clean_up_disk
100
+ r . scm . checkout ( r , url )
101
+ end
102
+
96
103
logger . debug { "Committing revision #{ r . token } (#{ i +1 } of #{ commits . size } )... " }
97
104
commit_all ( r )
98
105
end
Original file line number Diff line number Diff line change @@ -132,5 +132,11 @@ def opt_auth
132
132
opt_password = "--username='#{ self . username } ' --password='#{ self . password } '" if self . username && self . username != ''
133
133
" #{ opt_password } --no-auth-cache "
134
134
end
135
+
136
+ class << self
137
+ def has_conflicts? ( working_copy_url )
138
+ system ( "cd '#{ working_copy_url } ' && svn status | grep 'Summary of conflicts'" )
139
+ end
140
+ end
135
141
end
136
142
end
You can’t perform that action at this time.
0 commit comments