diff options
author | 2021-03-26 14:54:07 -0400 | |
---|---|---|
committer | 2021-03-26 14:54:07 -0400 | |
commit | 877671523c18aad4bb5061a1a2379beb5c761e3c (patch) | |
tree | d4fe0c210d2a19daaaed122e3e02f98cdc29ffe4 /bot/exts/evergreen/githubinfo.py | |
parent | Make requested changes (diff) |
Make repository accept either user/reponame or user reponame
Diffstat (limited to 'bot/exts/evergreen/githubinfo.py')
-rw-r--r-- | bot/exts/evergreen/githubinfo.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/bot/exts/evergreen/githubinfo.py b/bot/exts/evergreen/githubinfo.py index 1b64b0eb..c8a6b3f7 100644 --- a/bot/exts/evergreen/githubinfo.py +++ b/bot/exts/evergreen/githubinfo.py @@ -102,12 +102,17 @@ class GithubInfo(commands.Cog): await ctx.send(embed=embed) @github_group.command(name='repository', aliases=('repo',)) - async def github_repo_info(self, ctx: commands.Context, repo: str) -> None: - """Fetches a repositories' GitHub information. The repository should look like `user/reponame`.""" + async def github_repo_info(self, ctx: commands.Context, *repo: str) -> None: + """ + Fetches a repositories' GitHub information. + + The repository should look like `user/reponame` or `user reponame`. + """ + repo = '/'.join(repo) if repo.count('/') != 1: embed = discord.Embed( title=random.choice(NEGATIVE_REPLIES), - description="The repository should look like `user/reponame`.", + description="The repository should look like `user/reponame` or `user reponame`.", colour=Colours.soft_red ) |