Add an executable to the RubyGem package.

 @param name [Symbol] that will be used to retrieve this executable later.
 @param path [File] relative path to the executable that will be associated
 with this name.
12441
def add_executable name, path
      path = expand_local_path path
      executables << OpenStruct.new( :name => name, :path => path, :file_target => self )
    end
761482
def paths
      relative_paths = gem_names.flat_map do |plugin|
        Dir.glob("vendor/gems/ruby/*/gems/#{plugin}*/lib/**/**/**/**.rb")
      end

      relative_paths.map { |path| File.join(dir, path) }
    end
705955
def add_path(self, path):
        

        if os.path.exists(path):
            self.paths.add(path)
            return path
        else:
            #logger.debug('Path {} doesn\'t exist'.format(path))
            return None
711480
def add_config_path(path):
    
    if not os.path.isfile(path):
        warnings.warn("Config file does not exist: {path}".format(path=path))
        return False

    # select parser by file extension
    _base, ext = os.path.splitext(path)
    if ext and ext[1:] in PARSERS:
        parser = ext[1:]
    else:
        parser = PARSER
    parser_class = PARSERS[parser]

    _check_parser(parser_class, parser)
    if parser != PARSER:
        msg = (
            "Config for {added} parser added, but used {used} parser. "
            "Set up right parser via env var: "
            "export LUIGI_CONFIG_PARSER={added}"
        )
        warnings.warn(msg.format(added=parser, used=PARSER))

    # add config path to parser
    parser_class.add_config_path(path)
    return True
1055349
def file(name, &block)
      path = @path + name
      unless ::File.file?(path)
        FileUtils.touch(path)
        @ctx.add(path)
      end
      f = File.new(@ctx, path)
      f.instance_eval(&block) if block_given?
      f
    end
1064132
public void mkPackage(String name) throws IOException {
        File metaDir = new File(getAssetLoc() + "/" + name.replace('.', '/') + "/.mdw");
        if (!metaDir.exists() && !metaDir.mkdirs())
            throw new IOException("Cannot create directory: " + metaDir.getAbsolutePath());
        File pkgFile = new File(metaDir + "/package.yaml");
        if (!pkgFile.exists()) {
            JSONObject pkgJson = new JSONObject();
            pkgJson.put("name", name);
            pkgJson.put("version", "1.0.01");
            pkgJson.put("schemaVersion", "6.1");
            Files.write(Paths.get(pkgFile.getPath()), pkgJson.toString(2).getBytes());
        }
    }
1229142
def _add_asset_bundle(cls, path):
        
        f = "%s/assets.yml" % path
        if os.path.isfile(f):
            cls._asset_bundles.add(f)
1075078
private function addHelper(string $name, string $path): void
    {
        $class = static::class;

        // create store of helpers for this class
        if (!isset(static::$helpers[$class])) {
            static::$helpers[$class] = [];
        }

        $helper = include $path;

        if (\is_callable($helper)) {
            static::$helpers[$class][$name] = $helper;
        } else {
            throw new CommonException("Helper `$name` not found in file `$path`");
        }
    }
980739
def load_path(path)
      path = path.to_s
      check_error_string do
        @path = Pathname.new(path)
        load_path_impl(path)
      end
      self
    end
767221
def append_path(path)
      self.config = hash_reassoc(config, :paths) do |paths|
        path = File.expand_path(path, config[:root]).freeze
        paths.push(path)
      end
    end
701599
def load_from(gemspec_path, pattern)
      Gem.refresh
      spec = Gem::Specification.load(gemspec_path)
      dependencies = spec.runtime_dependencies.concat(spec.development_dependencies)
      dependencies.each do |gem|
        gem_name = gem.name[pattern]
        next if gem_name.to_s.empty?
        register(gem_name, Plugin.new(gem_name, gem))
      end
      self
    end
492948
protected function _mkfile($path, $name) {
		return $this->make($path, $name, 'text/plain') ? $this->_joinPath($path, $name) : false;
	}
981843
def _install_from_path(path):
    '''
    
    '''
    if not os.path.exists(path):
        msg = 'File not found: {0}'.format(path)
        raise SaltInvocationError(msg)

    cmd = 'installer -pkg "{0}" -target /'.format(path)
    return salt.utils.mac_utils.execute_return_success(cmd)
1023927
public function addScript($name, $path)
    {
        if (isset($this->scripts->$name)) {
            $this->scripts->$name[] = $path;
        } else {
            $this->scripts->$name = [$path];
        }

        return $this;
    }
199609
function init(path, name) {  // {{{2
/**
 * Class constructor
 *
 * @param name {String} Name of HttpContent instance
 * @param path {String} Path to content
 *
 * @method init
 */

  this.modules = {};
  this.handlers = {};
  this.scripts = [];
  this.styles = [];

  this.path = path || Path.dirname(this.O.module.filename);
  this.name = name || this.O.packageName || this.O.package.packageName;

//  O.log.debug('Content', this.toString());

  Http.addContent(this);

  this.addFiles && this.addFiles();
}
1125595
def file(name)
      files.find {|file| file.file_ref.name == name or file.file_ref.path == name  }
    end
265189
def add_dep(self, name, dep):
        
        logger.debug("name: %s, dep: %s", name, dep)

        if dep not in self._deps:
            self._deps[name] = dep