Python setuptools.command.develop.develop.run() Examples

The following are 30 code examples of setuptools.command.develop.develop.run(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module setuptools.command.develop.develop , or try the search function .
Example #1
Source File: setup.py    From renku-python with Apache License 2.0 6 votes vote down vote up
def run(self):
        from renku.core.commands.init import fetch_template, \
            read_template_manifest

        with TemporaryDirectory() as tempdir:
            # download and extract template data
            temppath = Path(tempdir)
            print('downloading Renku templates...')
            fetch_template(URL, REFERENCE, temppath)
            read_template_manifest(temppath, checkout=True)

            # copy templates
            current_path = Path.cwd()
            template_path = current_path / 'renku' / 'templates'
            if template_path.exists():
                shutil.rmtree(str(template_path))
            shutil.copytree(
                str(temppath),
                str(template_path),
                ignore=shutil.ignore_patterns('.git')
            ) 
Example #2
Source File: setup.py    From yatsm with MIT License 6 votes vote down vote up
def run(self):
        _clean.run(self)
        if os.path.exists('build'):
            shutil.rmtree('build')
        for dirpath, dirnames, filenames in os.walk('yatsm'):
            for filename in filenames:
                if any(filename.endswith(suffix) for suffix in
                       ('.c', '.so', '.pyd', '.pyc')):
                    os.unlink(os.path.join(dirpath, filename))
                    continue
                if (any(filename.endswith(suffix) for suffix in
                        ('.pkl', '.json')) and
                        os.path.basename(dirpath) == 'pickles'):
                    os.unlink(os.path.join(dirpath, filename))
            for dirname in dirnames:
                if dirname == '__pycache__':
                    shutil.rmtree(os.path.join(dirpath, dirname))


# Create pickles when building 
Example #3
Source File: setup.py    From sourcetracker2 with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def run(self):
        develop.run(self)
        custom_command() 
Example #4
Source File: setup.py    From meshpy with Apache License 2.0 5 votes vote down vote up
def run(self):
        os.system('sh install_meshrender.sh')
        develop.run(self) 
Example #5
Source File: setup.py    From apertium-python with GNU General Public License v3.0 5 votes vote down vote up
def run(self) -> None:
        develop.run(self)
        install_binaries() 
Example #6
Source File: setup_hook.py    From GH-License with GNU General Public License v3.0 5 votes vote down vote up
def run(self):
        main_path = os.path.expanduser("~/.gh-license")

        git_templates_path = "{}/git-templates".format(main_path)
        git_hooks_path = "{}/hooks".format(git_templates_path)

        config_path = "{}/config.ini".format(main_path)

        # copy the hooks folder in our git template folder
        shutil.copytree("setup/hooks", git_hooks_path)

        get_config_arguments = ["git", "config",
                                "--global", "init.templatedir"]

        if not os.path.exists(config_path):
            # save the current init.templatedir git config if the user already
            # had a value set for this
            try:
                current_config = subprocess.check_output(get_config_arguments)

                config = ConfigParser()

                config.read(config_path)
                config.add_section("main")
                config.set("main", "templatedir",
                           current_config.decode("utf-8"))

                with open(config_path, "w") as config_file:
                    config.write(config_file)
            except subprocess.CalledProcessError:
                pass  # don't create the config file

        # set our own git template path for the init.templatedir config
        set_config_arguments = get_config_arguments + [git_templates_path]

        subprocess.call(set_config_arguments)

        develop.run(self) 
Example #7
Source File: setup.py    From apertium-python with GNU General Public License v3.0 5 votes vote down vote up
def run(self) -> None:
        install.run(self)
        install_binaries() 
Example #8
Source File: setup.py    From old-sovrin with Apache License 2.0 5 votes vote down vote up
def post_install():
    subprocess.run(['python post-setup.py'], shell=True) 
Example #9
Source File: setup.py    From gntp with MIT License 5 votes vote down vote up
def run(self):
        install_prerequisites()
        _develop.run(self) 
Example #10
Source File: setup.py    From gntp with MIT License 5 votes vote down vote up
def run(self):
        _install.do_egg_install(self)
        install_prerequisites()
        _install.run(self) 
Example #11
Source File: setup.py    From meshpy with Apache License 2.0 5 votes vote down vote up
def run(self):
        os.system('sh install_meshrender.sh')
        install.run(self) 
Example #12
Source File: setup.py    From old-sovrin with Apache License 2.0 5 votes vote down vote up
def do_egg_install(self):
        install.run(self)
        post_install() 
Example #13
Source File: setup.py    From python-hunter with BSD 2-Clause "Simplified" License 5 votes vote down vote up
def run(self):
        build.run(self)
        src = join(dirname(__file__), 'src', 'hunter.embed')
        path = join(dirname(__file__), 'src', 'hunter.pth')
        with open(src) as sh:
            with open(path, 'w') as fh:
                fh.write(
                    'import os, sys;'
                    'exec(%r)' % sh.read().replace('    ', ' ')
                )
        dest = join(self.build_lib, basename(path))
        self.copy_file(path, dest) 
Example #14
Source File: setup.py    From funky with MIT License 5 votes vote down vote up
def run(self):
        post_install.run()
        develop.run(self) 
Example #15
Source File: setup.py    From funky with MIT License 5 votes vote down vote up
def run(self):
        post_install.run(self)
        install.run(self) 
Example #16
Source File: setup.py    From py3270 with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def run(self):
        # add in requirements for testing only when using the develop command
        self.distribution.install_requires.extend(["pytest", "pytest-cov"])
        STDevelopCmd.run(self) 
Example #17
Source File: setup.py    From sourcetracker2 with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def run(self):
        egg_info.run(self)
        custom_command() 
Example #18
Source File: setup.py    From python-hunter with BSD 2-Clause "Simplified" License 5 votes vote down vote up
def run(self):
        install_lib.run(self)
        path = join(dirname(__file__), 'src', 'hunter.pth')
        dest = join(self.install_dir, basename(path))
        self.copy_file(path, dest)
        self.outputs = [dest] 
Example #19
Source File: setup.py    From sourcetracker2 with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def run(self):
        install.run(self)
        custom_command() 
Example #20
Source File: setup.py    From ipmininet with GNU General Public License v2.0 5 votes vote down vote up
def run(self):
        setup_mininet_dep()
        install.run(self) 
Example #21
Source File: setup.py    From ipmininet with GNU General Public License v2.0 5 votes vote down vote up
def run(self):
        setup_mininet_dep()
        develop.run(self) 
Example #22
Source File: setup.py    From PointNetGPD with MIT License 5 votes vote down vote up
def run(self):
        install.run(self) 
Example #23
Source File: setup.py    From PointNetGPD with MIT License 5 votes vote down vote up
def run(self):
        develop.run(self) 
Example #24
Source File: setup.py    From scrounger with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def run(self):
        _create_custom_modules_paths()
        develop.run(self) 
Example #25
Source File: setup.py    From scrounger with BSD 3-Clause "New" or "Revised" License 5 votes vote down vote up
def run(self):
        _create_custom_modules_paths()
        install.run(self) 
Example #26
Source File: setup.py    From shellphish-afl with BSD 2-Clause "Simplified" License 5 votes vote down vote up
def run(self):
        self.execute(_setup_other_arch, (), msg="Setting up AFL-other-arch")
        self.execute(_setup_cgc, (), msg="Setting up AFL-cgc")
        self.execute(_setup_libs, (), msg="Getting libraries")
        _datafiles()
        _develop.run(self) 
Example #27
Source File: setup.py    From shellphish-afl with BSD 2-Clause "Simplified" License 5 votes vote down vote up
def run(self):
        self.execute(_setup_other_arch, (), msg="Setting up AFL-other-arch")
        self.execute(_setup_cgc, (), msg="Setting up AFL-cgc")
        self.execute(_setup_libs, (), msg="Getting libraries")
        _datafiles()
        _build.run(self) 
Example #28
Source File: setup.py    From jack with MIT License 5 votes vote down vote up
def run(self):
        spacy_download_en()
        _develop.run(self) 
Example #29
Source File: setup.py    From jack with MIT License 5 votes vote down vote up
def run(self):
        _install.do_egg_install(self)
        spacy_download_en()
        _install.run(self) 
Example #30
Source File: setup.py    From renku-python with Apache License 2.0 5 votes vote down vote up
def run(self):
        self.run_command('DownloadTemplates')
        _develop.run(self)