• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python sdist.run函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中setuptools.command.sdist.sdist.run函数的典型用法代码示例。如果您正苦于以下问题:Python run函数的具体用法?Python run怎么用?Python run使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了run函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。

示例1: run

    def run(self):
        sdist.run(self)

        # it would be nice to clean up MANIFEST.in and plotdevice.egg-info here,
        # but we'll see if the upload command depends on them...
        remove_tree('plotdevice.egg-info')
        os.unlink('MANIFEST.in')
开发者ID:VinayPrakashSingh,项目名称:plotdevice,代码行数:7,代码来源:setup.py


示例2: run

    def run(self):
        global version
        global release

        # Create a development release string for later use
        git_head = subprocess.Popen("git log -1 --pretty=format:%h",
                                    shell=True,
                                    stdout=subprocess.PIPE).communicate()[0].strip()
        date = time.strftime("%Y%m%d%H%M%S", time.gmtime())
        git_release = "%sgit%s" % (date, git_head)

        # Expand macros in pyrax.spec.in
        spec_in = open('pyrax.spec.in', 'r')
        spec = open('pyrax.spec', 'w')
        for line in spec_in.xreadlines():
            if "@[email protected]" in line:
                line = line.replace("@[email protected]", version)
            elif "@[email protected]" in line:
                # If development release, include date+githash in %{release}
                if release.startswith('0'):
                    release += '.' + git_release
                line = line.replace("@[email protected]", release)
            spec.write(line)
        spec_in.close()
        spec.close()

        # Run parent constructor
        _sdist.run(self)
开发者ID:rsyed83,项目名称:pyrax,代码行数:28,代码来源:setup.py


示例3: run

    def run(self):
        if git_version:
            subprocess.Popen(
                "sed -ri 's/VERSION = (.+)/VERSION = \"%s\"/' %s/__init__.py" % (git_version, name), shell=True
            ).communicate()

        sdist.run(self)
开发者ID:schmeitz,项目名称:motioneye,代码行数:7,代码来源:setup.py


示例4: run

 def run(self):
     try:
         import shutil
         shutil.copyfile('.libs/libgumbo.so', 'python/gumbo/libgumbo.so')
         sdist.run(self)
     except IOError as e:
         print(e)
开发者ID:ALEXGUOQ,项目名称:gumbo-parser,代码行数:7,代码来源:setup.py


示例5: run

 def run(self):
   run_make_files(
       make_docs=not self.no_make_docs,
       make_ui_files=not self.no_make_ui_files,
       force_compile_protos=not self.no_compile_protos,
       sync_artifacts=not self.no_sync_artifacts)
   sdist.run(self)
开发者ID:carriercomm,项目名称:grr,代码行数:7,代码来源:setup.py


示例6: run

    def run(self):
        input_dir = './docs/sphinx'
        build_doctree_dir = './build/doctrees'
        build_output_dir = './build/man'
        output_dir = DOC_MAN_PATH

        if os.path.exists(build_doctree_dir):
            shutil.rmtree(build_doctree_dir)
        if os.path.exists(build_output_dir):
            shutil.rmtree(build_output_dir)

        # sphinx doc generation
        sphinx.build_main(['sphinx-build',
                           '-c', input_dir,
                           '-b', 'man',
                           '-T',
                           '-d', build_doctree_dir,
                           # input dir
                           input_dir,
                           # output dir
                           build_output_dir])

        # copy to docs folder
        if os.path.exists(output_dir):
            shutil.rmtree(output_dir)
        shutil.copytree(build_output_dir, output_dir)

        # actual sdist
        sdist.run(self)
开发者ID:bhelm,项目名称:btrfs-sxbackup,代码行数:29,代码来源:setup.py


示例7: run

 def run(self):
     # try to run prep if needed
     try:
         prep()
     except:
         pass
     _sdist.run(self)
开发者ID:Hangjun,项目名称:vowpal_wabbit,代码行数:7,代码来源:setup.py


示例8: run

    def run(self):
        if not self.dry_run:
            with open(SKIP_CYTHON_FILE, 'w') as flag_file:
                flag_file.write('COMPILE_FROM_C_ONLY')

            sdist.run(self)

            os.remove(SKIP_CYTHON_FILE)
开发者ID:pythongssapi,项目名称:python-gssapi,代码行数:8,代码来源:setup.py


示例9: run

 def run(self):
     try:
         from Cython.Build import cythonize
         cythonize(os.path.join('pyhsmm','**','*.pyx'))
     except:
         warn('Failed to generate extension files from Cython sources')
     finally:
         _sdist.run(self)
开发者ID:garyfeng,项目名称:pyhsmm,代码行数:8,代码来源:setup.py


示例10: run

 def run(self):
     try:
         import shutil
         shutil.copyfile('.libs/' + _name_of_lib,
             'python/gumbo/' + _name_of_lib)
         sdist.run(self)
     except IOError as e:
         print(e)
开发者ID:JordanMilne,项目名称:gumbo-parser,代码行数:8,代码来源:setup.py


示例11: run

 def run(self):
     if os.path.isdir('.git'):
         git_log_gnu = 'git log --format="%ai %aN %n%n%x09* %s%d%n"'
         changelog = run_git_command(git_log_gnu)
         mailmap = parse_mailmap()
         with open("ChangeLog", "w") as changelog_file:
             changelog_file.write(str_dict_replace(changelog, mailmap))
     sdist.run(self)
开发者ID:markmc,项目名称:melange,代码行数:8,代码来源:setup.py


示例12: run

 def run(self):
         if self.disabledl :
             print("Automatic downloading of DShield and Spamhaus databases is disabled.")
             print("As a result, they won't be included in the generated source distribution.")
         else:
             self._downloadDatabase("DShield", "http://www.dshield.org/ipsascii.html?limit=10000", "preludecorrelator/plugins/dshield.dat")
             self._downloadDatabase("Spamhaus", "http://www.spamhaus.org/drop/drop.lasso", "preludecorrelator/plugins/spamhaus_drop.dat")
         sdist.run(self)
开发者ID:4sp1r3,项目名称:prelude-correlator,代码行数:8,代码来源:setup.py


示例13: run

    def run(self):
        self.run_command('build_man')

        # Run if available:
        if 'qt_resources' in self.distribution.cmdclass:
            self.run_command('qt_resources')

        sdist.run(self)
开发者ID:RAJATVALECHA,项目名称:mine,代码行数:8,代码来源:__init__.py


示例14: run

  def run(self):
    # Compile the protobufs.
    base_dir = os.getcwd()
    subprocess.check_call(["python", "makefile.py"])

    # Sync the artifact repo with upstream for distribution.
    subprocess.check_call(["python", "makefile.py"], cwd="grr/artifacts")

    sdist.run(self)
开发者ID:kevinnguyeneng,项目名称:grr,代码行数:9,代码来源:setup.py


示例15: run

    def run(self):
        global __version__
        __version__ = get_version(False)
        with open("version.txt", "w") as fd:
            fd.write(__version__)

        # Need to use old style super class invocation here for
        # backwards compatibility.
        sdist.run(self)
开发者ID:Onager,项目名称:dotty,代码行数:9,代码来源:setup.py


示例16: run

 def run(self):
     if self.disabledl:
         print("Automatic downloading of databases is disabled.")
         print("As a result, they won't be included in the generated source distribution.")
     else:
         self._downloadDatabase("DShield", "http://www.dshield.org/ipsascii.html?limit=10000", "rules/dshield.dat")
         self._downloadDatabase("Spamhaus", "http://www.spamhaus.org/drop/drop.lasso", "rules/spamhaus_drop.dat")
         self._downloadDatabase("CIArmy", "http://cinsscore.com/list/ci-badguys.txt", "rules/ciarmy.dat")
     sdist.run(self)
开发者ID:Prelude-SIEM,项目名称:prelude-correlator,代码行数:9,代码来源:setup.py


示例17: run

    def run(self):
        if os.path.isdir(".git"):
            # We're in a Git branch

            log_cmd = subprocess.Popen(["git", "log"], stdout=subprocess.PIPE)
            changelog = log_cmd.communicate()[0]
            with open("ChangeLog", "w") as changelog_file:
                changelog_file.write(changelog)
        sdist.run(self)
开发者ID:jplock,项目名称:flomosa,代码行数:9,代码来源:setup.py


示例18: run

 def run(self):
     if 'cython' in cmdclass:
         self.run_command('cython')
     else:
         for pyxfile in self._pyxfiles:
             cfile = pyxfile[:-3] + 'c'
             msg = "C-source file '%s' not found."%(cfile)+\
             " Run 'setup.py cython' before sdist."
             assert os.path.isfile(cfile), msg
     sdist.run(self)
开发者ID:blackwithwhite666,项目名称:pyhashring,代码行数:10,代码来源:setup.py


示例19: run

    def run(self):
        try:
            from Cython.Build import cythonize

            cythonize([
                module.replace('.', '/') + '.pyx' for module in cython_modules
            ])
        except ImportError:
            pass
        _sdist.run(self)
开发者ID:thriftrw,项目名称:thriftrw-python,代码行数:10,代码来源:setup.py


示例20: run

    def run(self):
        if os.path.isdir('.bzr'):
            # We're in a bzr branch

            log_cmd = subprocess.Popen(["bzr", "log", "--gnu"],
                                       stdout=subprocess.PIPE)
            changelog = log_cmd.communicate()[0]
            with open("ChangeLog", "w") as changelog_file:
                changelog_file.write(changelog)
        sdist.run(self)
开发者ID:github-lmp,项目名称:zft,代码行数:10,代码来源:setup.py



注:本文中的setuptools.command.sdist.sdist.run函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python setopt.edit_config函数代码示例发布时间:2022-05-27
下一篇:
Python sdist.make_release_tree函数代码示例发布时间:2022-05-27
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap