コード例 #1
0
def install_script_packages(event, options, project=None, **kwargs):
    # ensure we're in the project's root directory
    with in_directory(project.path()):
        install_script = project.path('./scripts/install.sh')
        if not os.path.exists(install_script):
            return

        # Installs the bundle requirements and the bins for each
        # requirement in the project's bin path
        call_subprocess(['bash', install_script, project.env_path()])
コード例 #2
0
ファイル: plugin.py プロジェクト: ravenac95/virtstrap-npm
def install_npm_packages(event, options, project=None, **kwargs):
    # ensure we're in the project's root directory
    with in_directory(project.path()):
        npm_path = which('npm')
        if not npm_path:
            logger.warning('Skipping node requirements. '
                    'npm must be installed on your system')
            return
        # Installs the bundle requirements and the bins for each
        # requirement in the project's bin path
        call_subprocess(['npm', 'install'])
コード例 #3
0
def install_ruby_bundler_requirements(event, options, project=None, **kwargs):
    # ensure we're in the project's root directory
    with in_directory(project.path()):
        # Check that bundler is installed on the system
        bundler_path = which('bundle')
        if not bundler_path:
            logger.warning('Skipping Ruby Requirements. '
                    'Bundler must be installed in your system')
            return
        # Installs the bundle requirements and the bins for each
        # requirement in the project's bin path
        call_subprocess([bundler_path, 'install',
            '--binstubs=%s' % project.bin_path()])
コード例 #4
0
 def call_bin(self, command_name, args, **options):
     command = [self.bin_path(command_name)]
     command.extend(args)
     return call_subprocess(command, **options)
コード例 #5
0
ファイル: project.py プロジェクト: pombredanne/virtstrap-core
 def call_bin(self, command_name, args, **options):
     command = [self.bin_path(command_name)]
     command.extend(args)
     return call_subprocess(command, **options)