jw-pkg/src/python/jw/pkg/cmds/CmdProjects.py
Jan Lindemann c8036ad216 jw-pkg.sh: Print help for missing subcommands
Print a help message if no subcommand is specified for one of the
comamnds "distro" and "projects".

Signed-off-by: Jan Lindemann <jan@janware.com>
2026-02-24 14:52:25 +01:00

21 lines
551 B
Python

# -*- coding: utf-8 -*-
import sys
from argparse import ArgumentParser
from ..App import App
from .Cmd import Cmd as CmdBase
class CmdProjects(CmdBase): # export
def __init__(self, parent: App) -> None:
super().__init__(parent, 'projects', help='Project metadata evaluation for building packages')
self._add_subcommands()
def add_arguments(self, p: ArgumentParser) -> None:
super().add_arguments(p)
async def _run(self, args):
# Missing subcommand
self.parser.print_help()
sys.exit(1)