Remove trailing slashes in nexus_url 05/10205/1
authorThanh Ha <thanh.ha@linuxfoundation.org>
Tue, 24 Apr 2018 16:53:33 +0000 (12:53 -0400)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Tue, 24 Apr 2018 16:53:37 +0000 (12:53 -0400)
lftools should not fail if the user passes extra trailing slashes that
the command was not expecting.

Change-Id: I9a32c48ddd5ee2898816db7faaeb0de805a38b3c
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
lftools/cli/sign.py

index 1893024..e93a70f 100644 (file)
@@ -63,6 +63,7 @@ def deploy_nexus(ctx, nexus_url, nexus_repo, staging_profile_id, root_domain):
     # as a workaround we have to at least give it 1 directory deep. Since most
     # LF projects are 'org' domain default is org but can be override with the
     # -r option.
+    nexus_url = nexus_url.rstrip('/')
     nexus_repo_url = "{}/content/repositories/{}/{}".format(nexus_url, nexus_repo, root_domain)
     sign_dir = tempfile.mkdtemp(prefix='gpg-signatures.')