dhub-cli 0.1.1__py3-none-any.whl → 0.1.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
dhub/cli/app.py CHANGED
@@ -1,13 +1,31 @@
1
1
  """Main Typer app with subcommand registration."""
2
2
 
3
+ from importlib.metadata import version as pkg_version
4
+
3
5
  import typer
4
6
 
7
+
8
+ def _version_callback(value: bool) -> None:
9
+ if value:
10
+ typer.echo(f"dhub {pkg_version('dhub-cli')}")
11
+ raise typer.Exit()
12
+
13
+
5
14
  app = typer.Typer(
6
15
  name="dhub",
7
- help="Decision Hub - The package manager for AI agent skills",
8
16
  no_args_is_help=True,
9
17
  )
10
18
 
19
+
20
+ @app.callback()
21
+ def main(
22
+ version: bool = typer.Option(
23
+ False, "--version", "-V", help="Show version and exit.",
24
+ callback=_version_callback, is_eager=True,
25
+ ),
26
+ ) -> None:
27
+ """Decision Hub - The package manager for AI agent skills."""
28
+
11
29
  # Register top-level commands
12
30
  from dhub.cli.auth import login_command # noqa: E402
13
31
  from dhub.cli.registry import delete_command, install_command, list_command, publish_command # noqa: E402
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dhub-cli
3
- Version: 0.1.1
3
+ Version: 0.1.2
4
4
  Summary: The CLI package manager for AI agent skills
5
5
  Project-URL: Homepage, https://github.com/lfiaschi/decision-hub
6
6
  Project-URL: Repository, https://github.com/lfiaschi/decision-hub
@@ -19,7 +19,7 @@ Requires-Python: >=3.11
19
19
  Requires-Dist: httpx>=0.27.0
20
20
  Requires-Dist: pyyaml>=6.0.0
21
21
  Requires-Dist: rich>=13.0.0
22
- Requires-Dist: typer[all]>=0.12.0
22
+ Requires-Dist: typer>=0.12.0
23
23
  Provides-Extra: dev
24
24
  Requires-Dist: pytest>=8.0.0; extra == 'dev'
25
25
  Description-Content-Type: text/markdown
@@ -1,7 +1,7 @@
1
1
  dhub/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
2
2
  dhub/models.py,sha256=P0nJY8CMCMsiS3KK1ZhvAV-gLQnB6kjK1HTjSTBeAxA,816
3
3
  dhub/cli/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
4
- dhub/cli/app.py,sha256=Vkn-PCytu9XUWRTfsqURXT4vcAEf3j6tUrMWvmFKRpQ,1021
4
+ dhub/cli/app.py,sha256=eIC-G3msECmlXEL7z5DhG-t_2prQv135-IC4S51xCpk,1413
5
5
  dhub/cli/auth.py,sha256=aRaP5A00iTJMvj-cDC4LbqcgCHWHaTTj5cwH8m8Pz64,2787
6
6
  dhub/cli/config.py,sha256=39D-BopFh2pdW0oFxxbL9UiehODq-3UgvX-f-32Wog8,1844
7
7
  dhub/cli/keys.py,sha256=JIVxklYRstZyk_57GeZ8xWDsM0xliZCctXVwps_xXBE,2667
@@ -14,7 +14,7 @@ dhub/core/install.py,sha256=UJBpcL8hmPjrJGc-8e92dXVsS_z7Vbg3xMDgbMjybbI,4840
14
14
  dhub/core/manifest.py,sha256=LDTwTXm8peaQWoMHIai5xaArFswrx1hHWFcyeTiR9GI,7064
15
15
  dhub/core/runtime.py,sha256=Q4JHRd4HhP2MtytC_IkQ8uT3i33z82YL9q0nZIPFhTA,2338
16
16
  dhub/core/validation.py,sha256=ObnOTQMsk55KeerUbJCYd23jeMIYwmrc0KYTMCvtoTo,1383
17
- dhub_cli-0.1.1.dist-info/METADATA,sha256=xn2xdzRsbZT7UOd38b1oy4kdqdfcoZK_v3VOfiMFTVE,2207
18
- dhub_cli-0.1.1.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
19
- dhub_cli-0.1.1.dist-info/entry_points.txt,sha256=vyRYVaVMaUfD0QoXh4QU1AMDwxKgSWxL9-xdGrMcSH8,42
20
- dhub_cli-0.1.1.dist-info/RECORD,,
17
+ dhub_cli-0.1.2.dist-info/METADATA,sha256=AK6HIG0Xuz6bh66yLXRs21kdd7Va4gaHx95iDC6C5eI,2202
18
+ dhub_cli-0.1.2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
19
+ dhub_cli-0.1.2.dist-info/entry_points.txt,sha256=vyRYVaVMaUfD0QoXh4QU1AMDwxKgSWxL9-xdGrMcSH8,42
20
+ dhub_cli-0.1.2.dist-info/RECORD,,