Parcourir la source

cmd_pkg: added subcommand for pkg related rpc commands

Daniel-Constantin Mierla il y a 5 ans
Parent
commit
980defe669
1 fichiers modifiés avec 33 ajouts et 0 suppressions
  1. 33 0
      kamcli/commands/cmd_pkg.py

+ 33 - 0
kamcli/commands/cmd_pkg.py

@@ -0,0 +1,33 @@
+import click
+from kamcli.cli import pass_context
+from kamcli.iorpc import command_ctl
+
+
[email protected](
+    "pkg",
+    help="Private memory (pkg) management",
+    short_help="Private memory (pkg) management",
+)
+@pass_context
+def cli(ctx):
+    pass
+
+
[email protected]("stats", short_help="Show the stats for pkg memory")
+@pass_context
+def pkg_stats(ctx):
+    """Show the stats for pkg memory
+
+    \b
+    """
+    command_ctl(ctx, "pkg.stats", [])
+
+
[email protected]("info", short_help="Show the info for pkg memory manager")
+@pass_context
+def pkg_info(ctx):
+    """Show the info for pkg memory manager
+
+    \b
+    """
+    command_ctl(ctx, "pkg.info", [])