Surround git call in a try-catch to allow skipping
@@ -199,11 +199,16 @@ class common {
def clean = itemGit.status().clean
println "Is \"$itemName\" clean? $clean"
if (!clean) {
- println "$itemType has uncommitted changes. Aborting."
+ println "$itemType has uncommitted changes. Skipping."
return
}
println "Updating $itemType $itemName"
+
+ try {
itemGit.pull remote: defaultRemote
+ } catch (GrgitException exception) {
+ println "Unable to update $itemName, Skipping: ${exception.getMessage()}"
+ }
}
/**
