Skip to content

Commit

Permalink
Catch github url special case
Browse files Browse the repository at this point in the history
When using github urls, the code tries to test the detected name against
the previously provided name. If we didn't provide a name, though, this
would throw an exception.
  • Loading branch information
bwarden committed Apr 19, 2019
1 parent e4719d0 commit 473718d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion autospec/tarball.py
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ def name_and_version(name_arg, version_arg, filemanager):
m = re.search(pattern, url)
if m:
repo = m.group(2).strip()
if repo not in name:
if not name or repo not in name:
# Only take the repo name as the package name if it's more descriptive
name = repo
elif name != repo:
Expand Down

0 comments on commit 473718d

Please sign in to comment.