Installs the collection.
 @param manifest [String] path to the manifest file to use
 @return [Boolean] value of {Collection#install} or {Collection#install?}
160283
def install(manifest = 'manifest.yml')
      unless File.exist? manifest
        logger.fatal { "Manifest file '#{manifest}' does not exist." }
        return false
      end

      collection.load_manifest manifest
      result = options[:dryrun] ? collection.install? : collection.install

      msg = install_message(result, options[:dryrun])
      result ? logger.info(msg) : logger.error(msg)
      result
    end
705924
def install(opts):
    
    resources = _load(opts.resources, opts.output_dir)
    if opts.all:
        opts.resource_names = ALL
    success = _install(resources, opts.resource_names, opts.mirror_url,
                       opts.destination, opts.skip_top_level)
    if success:
        if not opts.quiet:
            print("All resources successfully installed")
        return 0
    else:
        if not opts.quiet:
            invalid = _invalid(resources, opts.resource_names)
            print("Unable to install some resources: {}".format(', '.join(invalid)))
        return 1
770089
def load_manifests(self):
        
        for path in self.plugin_paths:
            for item in os.listdir(path):
                item_path = os.path.join(path, item)
                if os.path.isdir(item_path):
                    self.load_manifest(item_path)
874184
def manifests_parse(self):
        ''''''
        self.manifests = []
        for manifest_path in self.find_manifests():
            if self.manifest_path_is_old(manifest_path):
                print("fw: Manifest (%s) is old; consider 'manifest download'" % (manifest_path))
            manifest = self.manifest_parse(manifest_path)
            if self.semver_major(manifest["format-version"]) != 1:
                print("fw: Manifest (%s) has major version %d; MAVProxy only understands version 1" % (manifest_path,manifest["format-version"]))
                continue
            self.manifests.append(manifest)
337301
def add_filepath(self, manifest, filepath, fullpath, copy=False):
        
        filepath = os.path.normpath(filepath)
        if self.manifests[manifest].add_filepath(filepath, fullpath, copy):
            # Only link if filepath was added
            self.manifests[manifest].make_link(filepath)
410689
def install_app(self, app_path, app_package):
        
        driver = self._current_application()
        driver.install_app(app_path)
        return driver.is_app_installed(app_package)
809785
def read_manifest(self):
        
        log.info("reading manifest file '%s'", self.manifest)
        manifest = open(self.manifest, 'rb')
        for line in manifest:
            # The manifest must contain UTF-8. See #303.
            if six.PY3:
                try:
                    line = line.decode('UTF-8')
                except UnicodeDecodeError:
                    log.warn("%r not UTF-8 decodable -- skipping" % line)
                    continue
            # ignore comments and blank lines
            line = line.strip()
            if line.startswith('#') or not line:
                continue
            self.filelist.append(line)
        manifest.close()
16999
def register_manifest(app, filename='manifest.json'):
    ''''''
    if current_app.config.get('TESTING'):
        return  # Do not spend time here when testing
    if not has_manifest(app, filename):
        msg = '{filename} not found for {app}'.format(**locals())
        raise ValueError(msg)
    manifest = _manifests.get(app, {})
    manifest.update(load_manifest(app, filename))
    _manifests[app] = manifest
391367
def process_only(manifest)
      only_list = Spiceweasel::Config[:only]
      return manifest if only_list.empty?
      only_list.each do |key|
        unless MANIFEST_OPTIONS.member?(key)
          STDERR.puts "ERROR: '--only #{key}' is an invalid option."
          STDERR.puts "ERROR: Valid options are #{MANIFEST_OPTIONS}."
          exit(-1)
        end
      end
      only_list.push("berksfile") if only_list.member?("cookbooks")
      only_list.push("data bags") if only_list.delete("data_bags")
      manifest.keep_if { |key, val| only_list.member?(key) }
    end
890828
def validate_module_dir(dir)
      # first check to see if manifests directory even exists when path is nil
      if dir.nil?
        dir = '.'
      elsif dir.instance_of?(Array)
        puts 'Retrospec - an array of module paths is not supported at this time'.fatal
        raise Retrospec::Puppet::InvalidModulePathError
      end
      dir = File.expand_path(dir)
      manifest_dir = File.join(dir, 'manifests')
      if !File.exist?(manifest_dir)
        puts "No manifest directory in #{manifest_dir}, cannot validate this is a module".fatal
        raise Retrospec::Puppet::NoManifestDirError
      else
        files = Dir.glob("#{manifest_dir}/**/*.pp")
        warn "No puppet manifest files found at #{manifest_dir}".warning if files.length < 1
        # validate the manifest files, because if one files doesn't work it affects everything
        files.each do |file|
          begin
            parser.parse_file(file)
          rescue Puppet::ParseError
            puts "Manifest file: #{file} has parser errors, please fix and re-check using\n puppet parser validate #{file}".fatal
            raise Retrospec::Puppet::ParserError
          rescue SystemExit => e
            puts "Manifest file: #{file} has parser errors, please fix and re-check using\n puppet parser validate #{file}".fatal
            raise Retrospec::Puppet::ParserError
          end
        end
      end
      dir
    end
332397
def _install_library(library_name)
      result = run_and_capture(flag_install_library, library_name)

      already_installed = result[:err].include?("Library is already installed: #{library_name}")
      success = result[:success] || already_installed

      @libraries_indexed = (@libraries_indexed || success) if library_name == WORKAROUND_LIB
      success
    end
814020
def install
      puts 'Resolving packages...'
      @graph = @resolver.resolve

      puts 'Solving dependencies...'
      (Populator.new results).populate

      puts 'Packages configured successfully!'
      nil
    rescue Solve::Errors::NoSolutionError => error
      Logger.arrow "No solution found: #{error}"
      Process.abort
    end
721590
def _get_versions_manifest(manifest_dir):
    
    all_pkgs = _manifest_progs + [p.get("name", p["cmd"]) for p in _cl_progs] + [p["name"] for p in _alt_progs]
    if os.path.exists(manifest_dir):
        out = []
        for plist in ["toolplus", "python", "r", "debian", "custom"]:
            pkg_file = os.path.join(manifest_dir, "%s-packages.yaml" % plist)
            if os.path.exists(pkg_file):
                with open(pkg_file) as in_handle:
                    pkg_info = yaml.safe_load(in_handle)
                if not pkg_info:
                    continue
                added = []
                for pkg in all_pkgs:
                    if pkg in pkg_info:
                        added.append(pkg)
                        out.append({"program": pkg, "version": pkg_info[pkg]["version"]})
                for x in added:
                    all_pkgs.remove(x)
        out.sort(key=lambda x: x["program"])
        for pkg in all_pkgs:
            out.append({"program": pkg, "version": ""})
        return out
659892
function Manifest(options) {
  this.options = options;
  this.destDir = options.destDir || process.cwd();
  this.content = {};
  this.filePath = path.join(this.destDir, MANIFEST_FILENAME);

  // get or create manifest content
  this.content = this.read();
}
444048
def install_file(source, dest, is_dir=false)
      if File.exists?(dest)
        print "#{dest} already exists. Overwrite it? (yes/no) "
        return unless ['y', 'yes', 'ok'].include? gets.chomp.downcase
      end
      is_dir ? FileUtils.cp_r(source, dest) : FileUtils.cp(source, dest)
      puts "installed #{dest}" unless ENV['RACK_ENV'] == 'test'
    end
891012
protected function installCustomScript()
	{
		//install script
		foreach ($this->extension->getManifest()->getInstallPHPFiles() as $script) {
		    if (is_string($script)) {
                $this->runExtensionScript($script);
            } elseif (is_array($script) && isset($script[0]) && is_string($script[0]) && !empty($script[0]) && isset($script[1]) && is_array($script[1])) {
                $this->runExtensionScript($script[0], $script[1]);
            } else {
		        \common_Logger::w("Ignored custom install script because it's call definition is malformed in extension manifest!");
            }
		}

	}
362300
def export_manifests
      @export_manifests ||= Array(@exports).map do |(name, block)|
        Decidim::Components::ExportManifest.new(name, self).tap do |manifest|
          block.call(manifest)
        end
      end
    end