當前位置: 首頁>>代碼示例>>Python>>正文


Python commands.Command類代碼示例

本文整理匯總了Python中cerbero.commands.Command的典型用法代碼示例。如果您正苦於以下問題:Python Command類的具體用法?Python Command怎麽用?Python Command使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了Command類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('package', nargs='*',
                          help=_('name of the package to create')),
         ArgparseArgument('-o', '--output-dir', default='.',
                          help=_('Output directory for the tarball file')),
         ArgparseArgument('-t', '--type', type=str, default='native',
             choices=['native', ArchiveType.TARBALL , ArchiveType.ZIP],
             help=_('Choose a package type, native or archive')),
         ArgparseArgument('-f', '--force', action='store_true',
             default=False, help=_('Delete any existing package file')),
         ArgparseArgument('-d', '--no-devel', action='store_true',
             default=False, help=_('Do not create the development version '
                 'of this package')),
         ArgparseArgument('-s', '--skip-deps-build', action='store_true',
             default=False, help=_('Do not build the recipes needed to '
                 'create this package (conflicts with --only-build-deps)')),
         ArgparseArgument('-b', '--only-build-deps', action='store_true',
             default=False, help=_('Only build the recipes needed to '
                 'create this package (conflicts with --skip-deps-build)')),
         ArgparseArgument('-k', '--keep-temp', action='store_true',
             default=False, help=_('Keep temporary files for debug')),
         ArgparseArgument('-u', '--use-binaries', action='store_true',
             default=False,
             help=_('use binaries from the repo before building')),
         ArgparseArgument('-p', '--upload-binaries', action='store_true',
             default=False,
             help=_('after a recipe is built upload the corresponding binary package')),
         ArgparseArgument('-m', '--build-missing', action='store_true',
             default=False,
             help=_('in case a binary package is missing try to build it')),
         ])
開發者ID:fluendo,項目名稱:cerbero,代碼行數:32,代碼來源:package.py

示例2: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('recipe', nargs=1,
                          help=_('name of the recipe to run checks on')),
         ArgparseArgument('--recursive', action='store_true', default=False,
                          help=_('Recursively run checks on dependencies')),
         ])
開發者ID:centricular,項目名稱:cerbero,代碼行數:7,代碼來源:check.py

示例3: __init__

    def __init__(self):
        self.supported_licenses = {}
        l = License
        for name in l.__dict__:
            attr = getattr(l, name)
            if not isinstance(attr, LicenseDescription):
                continue
            self.supported_licenses[attr.acronym] = name

        Command.__init__(self,
            [ArgparseArgument('name', nargs=1,
                             help=_('name of the recipe')),
            ArgparseArgument('version', nargs=1,
                             help=_('version of the recipe')),
            ArgparseArgument('-l', '--licenses', default='',
                             help=_('comma separated list of the recipe '
                                    'licenses. Supported licenses: %s') %
                                    ', '.join(list(self.supported_licenses.keys()))),
            ArgparseArgument('-c', '--commit', default='',
                             help=_('commit to use '
                                    '(default to "sdk-$version")')),
            ArgparseArgument('-o', '--origin', default='',
                             help=_('the origin repository of the recipe')),
            ArgparseArgument('-d', '--deps', default='',
                             help=_('comma separated list of the recipe '
                                    'dependencies')),
            ArgparseArgument('-f', '--force', action='store_true',
                default=False, help=_('Replace recipe if existing'))])
開發者ID:centricular,項目名稱:cerbero,代碼行數:28,代碼來源:add_recipe.py

示例4: __init__

    def __init__(self, force=None, no_deps=None):
            args = [
                ArgparseArgument('recipe', nargs='*',
                    help=_('name of the recipe to build')),
                ArgparseArgument('--missing-files', action='store_true',
                    default=False,
                    help=_('prints a list of files installed that are '
                           'listed in the recipe')),
                ArgparseArgument('--dry-run', action='store_true',
                    default=False,
                    help=_('only print commands instead of running them ')),
                ArgparseArgument('--use-binaries', action='store_true',
                    default=False,
                    help=_('use binaries from the repo before building')),
                ArgparseArgument('--upload-binaries', action='store_true',
                    default=False,
                    help=_('after a recipe is built upload the corresponding binary package')),
                ArgparseArgument('--build-missing', action='store_true',
                    default=False,
                    help=_('in case a binary package is missing try to build it'))]
            if force is None:
                args.append(
                    ArgparseArgument('--force', action='store_true',
                        default=False,
                        help=_('force the build of the recipe ingoring '
                                    'its cached state')))
            if no_deps is None:
                args.append(
                    ArgparseArgument('--no-deps', action='store_true',
                        default=False,
                        help=_('do not build dependencies')))

            self.force = force
            self.no_deps = no_deps
            Command.__init__(self, args)
開發者ID:fluendo,項目名稱:cerbero,代碼行數:35,代碼來源:build.py

示例5: __init__

 def __init__(self, args=[]):
     args.append(ArgparseArgument('--reset-rdeps', action='store_true',
                 default=False, help=_('reset the status of reverse '
                 'dependencies too')))
     args.append(ArgparseArgument('--full-reset', action='store_true',
                 default=False, help=_('reset to extract step if rebuild is needed')))
     Command.__init__(self, args)
開發者ID:AlertMe,項目名稱:cerbero,代碼行數:7,代碼來源:fetch.py

示例6: __init__

    def __init__(self, force=None, no_deps=None):
            args = [
                ArgparseArgument('recipe', nargs='*',
                    help=_('name of the recipe to build')),
                ArgparseArgument('--missing-files', action='store_true',
                    default=False,
                    help=_('prints a list of files installed that are '
                           'listed in the recipe')),
                ArgparseArgument('--dry-run', action='store_true',
                    default=False,
                    help=_('only print commands instead of running them '))]
            if force is None:
                args.append(
                    ArgparseArgument('--force', action='store_true',
                        default=False,
                        help=_('force the build of the recipe ingoring '
                                    'its cached state')))
            if no_deps is None:
                args.append(
                    ArgparseArgument('--no-deps', action='store_true',
                        default=False,
                        help=_('do not build dependencies')))

            self.force = force
            self.no_deps = no_deps
            Command.__init__(self, args)
開發者ID:AlertMe,項目名稱:cerbero,代碼行數:26,代碼來源:build.py

示例7: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('package', nargs=1,
                          help=_('name of the package to create')),
         ArgparseArgument('-o', '--output-dir', default='.',
                          help=_('Output directory for the tarball file')),
         ArgparseArgument('-t', '--tarball', action='store_true',
             default=False,
             help=_('Creates a tarball instead of a native package')),
         ArgparseArgument('-n', '--no-split', action='store_true',
             default=False,
             help=_('(only meaningfull when --tarball is set) Create one single '
                    'tarball with devel and runtime files')),
         ArgparseArgument('-f', '--force', action='store_true',
             default=False, help=_('Delete any existing package file')),
         ArgparseArgument('-d', '--no-devel', action='store_false',
             default=True, help=_('Do not create the development version '
                 'of this package')),
         ArgparseArgument('-s', '--skip-deps-build', action='store_true',
             default=False, help=_('Do not build the recipes needed to '
                 'create this package (conflicts with --only-build-deps)')),
         ArgparseArgument('-b', '--only-build-deps', action='store_true',
             default=False, help=_('Only build the recipes needed to '
                 'create this package (conflicts with --skip-deps-build)')),
         ArgparseArgument('-k', '--keep-temp', action='store_true',
             default=False, help=_('Keep temporary files for debug')),
         ])
開發者ID:GStreamer,項目名稱:cerbero,代碼行數:27,代碼來源:package.py

示例8: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('-o', '--output_dir', default='.',
             help=_('output directory where .vsprops files will be saved')),
          ArgparseArgument('-p', '--prefix', default=DEFAULT_PREFIX_MACRO,
              help=_('name of the prefix environment variable '
                     '(eg:CERBERO_SDK_ROOT_X86)')),
         ])
開發者ID:AlertMe,項目名稱:cerbero,代碼行數:8,代碼來源:genvsprops.py

示例9: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('package', nargs=1,
                          help=_('name of the package')),
         ArgparseArgument('-l', '--list-files', action='store_true',
             default=False,
             help=_('List all files installed by this package')),
         ])
開發者ID:centricular,項目名稱:cerbero,代碼行數:8,代碼來源:info.py

示例10: __init__

    def __init__(self):
        args = [
            ArgparseArgument('--use-system-libs', action='store_true',
                    default=False,
                    help=_('add system paths to PKG_CONFIG_PATH')),
        ]

        Command.__init__(self, args)
開發者ID:AlertMe,項目名稱:cerbero,代碼行數:8,代碼來源:shell.py

示例11: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('recipe', nargs=1,
                          help=_('name of the recipe')),
         ArgparseArgument('--all', action='store_true', default=False,
                          help=_('list all dependencies, including the '
                                 'build ones')),
         ])
開發者ID:BigBrother-International,項目名稱:gst-cerbero,代碼行數:8,代碼來源:deps.py

示例12: __init__

 def __init__(self):
     args = [
         ArgparseArgument('--dry-run', action='store_true',
             default=False,
             help=_('only print commands instead of running them ')),
         ArgparseArgument('-f', '--force', action='store_true',
             default=False, help=_('Force the creation of the binary package')),
     ]
     Command.__init__(self, args)
開發者ID:fluendo,項目名稱:cerbero,代碼行數:9,代碼來源:genbinaries.py

示例13: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('cmd', nargs='+',
                          help=_('command to run')),
          ArgparseArgument('-v', '--verbose',
                          action='store_true',
                          default=False,
                          help=_('verbose mode'))
         ])
開發者ID:GStreamer,項目名稱:cerbero,代碼行數:9,代碼來源:runit.py

示例14: __init__

 def __init__(self):
     Command.__init__(self, [
             ArgparseArgument('--force', action='store_true',
                 default=False,
                 help=_('force the deletion of everything without user '
                        'input')),
             ArgparseArgument('--build-tools', action='store_true',
                 default=False,
                 help=_('wipe the build tools too'))])
開發者ID:deepak6,項目名稱:cerbero,代碼行數:9,代碼來源:wipe.py

示例15: __init__

 def __init__(self):
     Command.__init__(self,
         [ArgparseArgument('-o', '--output_dir', default='.',
             help=_('output directory where .xcconfig files will be saved')),
         ArgparseArgument('-f', '--filename', default=None,
             help=_('filename of the .xcconfig file')),
         ArgparseArgument('libraries', nargs='*',
             help=_('List of libraries to include')),
         ])
開發者ID:AlertMe,項目名稱:cerbero,代碼行數:9,代碼來源:genxcconfig.py


注:本文中的cerbero.commands.Command類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。