Beispiel #1
0
def _check_label_args(args, ctx):
    cmd_impl_support.check_required_args(
        [
            "set",
            "append",
            "prepend",
            "remove",
            "clear",
        ],
        args,
        ctx,
    )
    cmd_impl_support.check_incompatible_args(
        [
            ("set", "append"),
            ("set", "prepend"),
            ("set", "remove"),
            ("set", "clear"),
            ("append", "prepend"),
            ("append", "clear"),
            ("append", "remove"),
            ("prepend", "clear"),
            ("prepend", "remove"),
        ],
        args,
        ctx,
    )
Beispiel #2
0
def _check_tag_args(args, ctx):
    cmd_impl_support.check_required_args(
        [
            "add",
            "delete",
            "clear",
        ],
        args,
        ctx,
    )
Beispiel #3
0
def _check_comment_args_for_remote(args, ctx):
    _check_comment_args(args, ctx)
    cmd_impl_support.check_incompatible_args(
        [
            ("remote", "edit"),
        ],
        args,
        ctx,
    )
    cmd_impl_support.check_required_args(
        [
            "list",
            "add",
            "delete",
            "clear",
        ],
        args,
        ctx,
        msg_template="--remote option required on of: %s",
    )