MCPcopy Create free account
hub / github.com/StackStorm/st2 / __init__

Method __init__

st2client/st2client/commands/resource.py:669–684  ·  view source on GitHub ↗
(self, resource, *args, **kwargs)

Source from the content-addressed store, hash-verified

667 pk_argument_name = "name_or_id"
668
669 def __init__(self, resource, *args, **kwargs):
670 super(ResourceDisableCommand, self).__init__(
671 resource,
672 "disable",
673 "Disable an existing %s." % resource.get_display_name().lower(),
674 *args,
675 **kwargs,
676 )
677
678 argument = self.pk_argument_name
679 metavar = self._get_metavar_for_argument(argument=self.pk_argument_name)
680 help = self._get_help_for_argument(
681 resource=resource, argument=self.pk_argument_name
682 )
683
684 self.parser.add_argument(argument, metavar=metavar, help=help)
685
686 @add_auth_token_to_kwargs_from_cli
687 def run(self, args, **kwargs):

Callers

nothing calls this directly

Calls 4

get_display_nameMethod · 0.80
__init__Method · 0.45

Tested by

no test coverage detected