##// END OF EJS Templates
subrepo: extend git version check to 3 digits...
Mathias De Maré -
r23522:49a58b33 default
parent child Browse files
Show More
@@ -1136,9 +1136,13 class gitsubrepo(abstractsubrepo):
1136
1136
1137 @staticmethod
1137 @staticmethod
1138 def _gitversion(out):
1138 def _gitversion(out):
1139 m = re.search(r'^git version (\d+)\.(\d+)\.(\d+)', out)
1140 if m:
1141 return (int(m.group(1)), int(m.group(2)), int(m.group(3)))
1142
1139 m = re.search(r'^git version (\d+)\.(\d+)', out)
1143 m = re.search(r'^git version (\d+)\.(\d+)', out)
1140 if m:
1144 if m:
1141 return (int(m.group(1)), int(m.group(2)))
1145 return (int(m.group(1)), int(m.group(2)), 0)
1142
1146
1143 return -1
1147 return -1
1144
1148
@@ -1172,9 +1176,9 class gitsubrepo(abstractsubrepo):
1172 # 1.5.0 but attempt to continue.
1176 # 1.5.0 but attempt to continue.
1173 if version == -1:
1177 if version == -1:
1174 return 'unknown'
1178 return 'unknown'
1175 if version < (1, 5):
1179 if version < (1, 5, 0):
1176 return 'abort'
1180 return 'abort'
1177 elif version < (1, 6):
1181 elif version < (1, 6, 0):
1178 return 'warning'
1182 return 'warning'
1179 return 'ok'
1183 return 'ok'
1180
1184
General Comments 0
You need to be logged in to leave comments. Login now