MCPcopy Index your code
hub / github.com/AstrBotDevs/AstrBot / display_plugins

Function display_plugins

astrbot/cli/commands/cmd_plug.py:32–46  ·  view source on GitHub ↗
(plugins, title=None, color=None)

Source from the content-addressed store, hash-verified

30
31
32def display_plugins(plugins, title=None, color=None) -> None:
33 if title:
34 click.echo(click.style(title, fg=color, bold=True))
35
36 click.echo(
37 f"{'Name':<20} {'Version':<10} {'Status':<10} {'Author':<15} {'Description':<30}"
38 )
39 click.echo("-" * 85)
40
41 for p in plugins:
42 desc = p["desc"][:30] + ("..." if len(p["desc"]) > 30 else "")
43 click.echo(
44 f"{p['name']:<20} {p['version']:<10} {p['status']:<10} "
45 f"{p['author']:<15} {desc:<30}",
46 )
47
48
49@plug.command()

Callers 2

listFunction · 0.85
searchFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected