custom-git: accept commit SHAs 7+ chars in length

This commit is contained in:
Jimmy Zelinskie 2015-05-20 12:53:43 -04:00
parent 598fc6ec46
commit fe3f0dc10b
2 changed files with 2 additions and 2 deletions

View file

@ -1048,7 +1048,7 @@ class CustomBuildTrigger(BuildTriggerHandler):
}
prepared = PreparedBuild(self.trigger)
prepared.tags = [commit_sha]
prepared.tags = [commit_sha[:7]]
prepared.name_from_sha(commit_sha)
prepared.subdirectory = config['subdir']
prepared.metadata = metadata

View file

@ -122,7 +122,7 @@ angular.module('quay').factory('TriggerService', ['UtilService', '$sanitize', 'K
'title': 'Commit',
'type': 'regex',
'name': 'commit_sha',
'regex': '^([A-Fa-f0-9]{7})$',
'regex': '^([A-Fa-f0-9]{7,})$',
'placeholder': '1c002dd'
}
],