Add links to the output of [p]repo list (#6284)

Co-authored-by: Seaswimmer <102361830+SeaswimmerTheFsh@users.noreply.github.com>
Co-authored-by: Kreusada <67752638+Kreusada@users.noreply.github.com>
This commit is contained in:
Seaswimmer 2024-10-29 14:10:02 -04:00 committed by GitHub
parent 4134881fae
commit 30058c0f73
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -648,14 +648,18 @@ class Downloader(commands.Cog):
joined = _("There are no repos installed.") joined = _("There are no repos installed.")
else: else:
if len(repos) > 1: if len(repos) > 1:
joined = _("# Installed Repos\n") joined = _("## Installed Repos\n")
else: else:
joined = _("# Installed Repo\n") joined = _("## Installed Repo\n")
for repo in sorted_repos: for repo in sorted_repos:
joined += "+ {}: {}\n".format(repo.name, repo.short or "") joined += "- **{}:** {}\n - {}\n".format(
repo.name,
repo.short or "",
"<{}>".format(repo.url),
)
for page in pagify(joined, ["\n"], shorten_by=16): for page in pagify(joined, ["\n"], shorten_by=16):
await ctx.send(box(page.lstrip(" "), lang="markdown")) await ctx.send(page)
@repo.command(name="info") @repo.command(name="info")
async def _repo_info(self, ctx: commands.Context, repo: Repo) -> None: async def _repo_info(self, ctx: commands.Context, repo: Repo) -> None: