maven_jar(): Clarify why 'SNAPSHOT' is discarded from directory name
Change-Id: Ic03082d418d118cf0395e667dd65ece4dce57c75
This commit is contained in:
parent
195b9d7ece
commit
fc5450b38c
@ -48,6 +48,12 @@ def maven_jar(
|
||||
raise NameError('expected id="groupId:artifactId:version"')
|
||||
group, artifact, version = parts
|
||||
|
||||
# SNAPSHOT artifacts are handled differently on Google storage bucket:
|
||||
# 'SNAPSHOT' is discarded from the directory name. However on other
|
||||
# Maven repositories, most notable local repository located in
|
||||
# ~/.m2/repository (and is supported through MAVEN_LOCAL repository)
|
||||
# it must be preserved, otherwise the artifact wouldn't be found.
|
||||
# Atm the SNAPSHOT part is only discarded for Google storage bucket.
|
||||
if 'SNAPSHOT' in version and repository.startswith(GERRIT):
|
||||
file_version = version.replace('-SNAPSHOT', '')
|
||||
version = version.split('-SNAPSHOT')[0] + '-SNAPSHOT'
|
||||
|
Loading…
Reference in New Issue
Block a user