Buck: Preserve SNAPSHOT suffix in Maven artifact names
Drop the code that removes SNAPSHOT suffix in artifact name. This prevents
Gitblit plugin from fetching its custom artifact from Gerritforge Maven
repository, making from the right name:
com/gitblit/gitblit/1.4.0-SNAPSHOT/gitblit-1.4.0-SNAPSHOT.jar
the broken artifact name:
com/gitblit/gitblit/1.4.0-SNAPSHOT/gitblit-1.4.0.jar
Change-Id: Ib16f032a9fda3ef61570a85d97659cd3ce02f5f2
diff --git a/lib/maven.defs b/lib/maven.defs
index 54840e8..a696580 100644
--- a/lib/maven.defs
+++ b/lib/maven.defs
@@ -47,17 +47,11 @@
raise NameError('expected id="groupId:artifactId:version"')
group, artifact, version = parts
- if 'SNAPSHOT' in version:
- file_version = version.replace('-SNAPSHOT', '')
- version = version.split('-SNAPSHOT')[0] + '-SNAPSHOT'
- else:
- file_version = version
-
- jar = path.join(name, artifact.lower() + '-' + file_version)
+ jar = path.join(name, artifact.lower() + '-' + version)
url = '/'.join([
repository,
group.replace('.', '/'), artifact, version,
- artifact + '-' + file_version])
+ artifact + '-' + version])
binjar = jar + '.jar'
binurl = url + '.jar'