Add dependent jars and files.
178646
private void addDependencies(Configuration conf) throws IOException {
    TimingEvent distributedCacheSetupTimer =
        this.eventSubmitter.getTimingEvent(TimingEvent.RunJobTimings.MR_DISTRIBUTED_CACHE_SETUP);

    Path jarFileDir = this.jarsDir;

    // Add framework jars to the classpath for the mappers/reducer
    if (this.jobProps.containsKey(ConfigurationKeys.FRAMEWORK_JAR_FILES_KEY)) {
      addJars(jarFileDir, this.jobProps.getProperty(ConfigurationKeys.FRAMEWORK_JAR_FILES_KEY), conf);
    }

    // Add job-specific jars to the classpath for the mappers
    if (this.jobProps.containsKey(ConfigurationKeys.JOB_JAR_FILES_KEY)) {
      addJars(jarFileDir, this.jobProps.getProperty(ConfigurationKeys.JOB_JAR_FILES_KEY), conf);
    }

    // Add other files (if any) the job depends on to DistributedCache
    if (this.jobProps.containsKey(ConfigurationKeys.JOB_LOCAL_FILES_KEY)) {
      addLocalFiles(new Path(this.mrJobDir, FILES_DIR_NAME),
          this.jobProps.getProperty(ConfigurationKeys.JOB_LOCAL_FILES_KEY), conf);
    }

    // Add files (if any) already on HDFS that the job depends on to DistributedCache
    if (this.jobProps.containsKey(ConfigurationKeys.JOB_HDFS_FILES_KEY)) {
      addHDFSFiles(this.jobProps.getProperty(ConfigurationKeys.JOB_HDFS_FILES_KEY), conf);
    }

    // Add job-specific jars existing in HDFS to the classpath for the mappers
    if (this.jobProps.containsKey(ConfigurationKeys.JOB_JAR_HDFS_FILES_KEY)) {
      addHdfsJars(this.jobProps.getProperty(ConfigurationKeys.JOB_JAR_HDFS_FILES_KEY), conf);
    }

    distributedCacheSetupTimer.stop();
  }
1117163
def add(self, addon, dev=False, interactive=True):
        """"""
        dependencies = self.get_dependency_manager(dev=dev)
        other_dependencies = self.get_dependency_manager(dev=not dev)
        existing = dependencies.get(addon)
        self.stdout.write(style.format_command('Adding', addon))
        dependencies.add(addon)
        try:
            # try running the build
            self.build()
            self.refresh()

            # remove version of this in other requirements file
            other_dependencies.remove(addon, warn=False)

            # run new addon constructor
            constructor_name = '%s.init' % Dependency(addon).module_name
            constructor = self.blueprints.get(constructor_name)

            if constructor:
                context = constructor.load_context().main(
                    [], standalone_mode=False
                )
                self.generate(constructor, context, interactive=interactive)
        except Exception as e:
            # restore original settings
            self.stdout.write(style.red(str(e)))
            self.stdout.write(
                style.yellow('Could not find %s' % addon)
            )
            dependencies.remove(addon)
            if existing:
                dependencies.add(existing)
            return
176969
private List<MavenDependencyDescriptor> addManagedDependencies(MavenDependentDescriptor pomDescriptor, DependencyManagement dependencyManagement,
            ScannerContext scannerContext, Class<? extends AbstractDependencyDescriptor> relationClass) {
        if (dependencyManagement == null) {
            return Collections.emptyList();
        }
        List<Dependency> dependencies = dependencyManagement.getDependencies();
        return getDependencies(pomDescriptor, dependencies, relationClass, scannerContext);
    }
954108
def apply_dependencies(self):
        
        for host in self:
            for parent_id in getattr(host, 'parents', []):
                if parent_id is None:
                    continue
                parent = self[parent_id]
                if parent.active_checks_enabled:
                    # Add parent in the list
                    host.act_depend_of.append((parent_id, ['d', 'x', 's', 'f'], '', True))

                    # Add child in the parent
                    parent.act_depend_of_me.append((host.uuid, ['d', 'x', 's', 'f'], '', True))

                    # And add the parent/child dep filling too, for broking
                    parent.child_dependencies.add(host.uuid)
                    host.parent_dependencies.add(parent_id)
403032
def update(self, other):
    """"""
    if self._pants_workdir != other._pants_workdir:
      raise ValueError('Other ClasspathProducts from a different pants workdir {}'.format(other._pants_workdir))
    for target, products in other._classpaths._products_by_target.items():
      self._classpaths.add_for_target(target, products)
    for target, products in other._excludes._products_by_target.items():
      self._excludes.add_for_target(target, products)
154553
public void addDependency(String name, String version) {

        CmsModuleVersion moduleVersion = new CmsModuleVersion(version);

        CmsModuleDependency dependency = new CmsModuleDependency(name, moduleVersion);
        m_dependencies.add(dependency);

        if (LOG.isDebugEnabled()) {
            LOG.debug(Messages.get().getBundle().key(Messages.LOG_ADD_MOD_DEPENDENCY_2, name, version));
        }
    }
366437
def add_pom_dependencies( pom_path, scopes=['compile'] )
      if Naether.platform == 'java'
        @resolver.addDependencies( pom_path, scopes )
      else
        list = Naether::Java.convert_to_java_list( scopes )
        @resolver._invoke( 'addDependencies', 'Ljava.lang.String;Ljava.util.List;', pom_path, list )
      end
    end
697897
public function addDependency($filename)
    {
        if (in_array($filename, $this->dependencies) == false) {
            $this->dependencies[] = $filename;
        }
    }
659272
def add_dependency(self, value):
        """"""
        if value.name in self.dependencies:
            self.dependencies[value.name.lower()].append(value)
        else:
            self.dependencies[value.name.lower()] = [ value ]
140622
def set_dependencies(analysis, dependencies, path):
    

    for toc in (analysis.binaries, analysis.datas):
        for i, tpl in enumerate(toc):
            if not tpl[1] in dependencies.keys():
                logger.info("Adding dependency %s located in %s" % (tpl[1], path))
                dependencies[tpl[1]] = path
            else:
                dep_path = get_relative_path(path, dependencies[tpl[1]])
                logger.info("Referencing %s to be a dependecy for %s, located in %s" % (tpl[1], path, dep_path))
                analysis.dependencies.append((":".join((dep_path, tpl[0])), tpl[1], "DEPENDENCY"))
                toc[i] = (None, None, None)
        # Clean the list
        toc[:] = [tpl for tpl in toc if tpl != (None, None, None)]
1017296
void addDependency(String moduleName, String version) {

        try {
            m_dependencies.addComponent(
                new CmsRemovableFormRow<CmsModuleDependencyWidget>(
                    CmsModuleDependencyWidget.create(
                        new CmsModuleDependency(moduleName, new CmsModuleVersion(version))),
                    ""));
        } catch (Exception e) {
            CmsErrorDialog.showErrorDialog(e);
        }
    }
387227
protected boolean addDependencies(DependencyContainer container)
  {
    /* XXX:
    if (_classPath instanceof JarPath) {
      container.add(_depend);
      return false;
    }
    else
    */ 
    if (_hasJNIReload) {
      container.add(this);
      return true;
    }
    else if (_sourcePath == null) {
      container.add(_depend);
      return false;
    }
    else {
      container.add(this);
      return true;
    }
  }
1149613
def copy_dependency_docs(tile):
    """"""

    env = Environment(tools=[])

    outputbase = os.path.join('build', 'output', 'doc')
    depbase = os.path.join('build', 'deps')
    for dep in tile.dependencies:
        depdir = os.path.join(depbase, dep['unique_id'], 'doc', dep['unique_id'])
        outputdir = os.path.join(outputbase, dep['unique_id'])

        if os.path.exists(depdir):
            env.Command([outputdir], [depdir], Copy("$TARGET", "$SOURCE"))
74971
public static void addDependencyFactory(Object... dependencyFactories) {
        for (Object dependencyFactory : dependencyFactories) {
            if (!dependencyFactory.getClass().isAnnotationPresent(DependencyFactory.class)) {
                throw new AvicennaRuntimeException(
                        dependencyFactory.getClass() + " should be annotated with DependencyFactory.");
            }
            if (Avicenna.dependencyFactories.contains(dependencyFactory.getClass())) {
                throw new AvicennaRuntimeException(
                        dependencyFactory.getClass() + " has already been added to container.");
            }
            addDependencyFactoryToContainer(dependencyFactory);
            Avicenna.dependencyFactories.add(dependencyFactory.getClass());
        }
    }
311492
function addModuleToDependencies(cwd, name, version) {
  version = version || 'latest';
  let pkgFile = { dependencies: {} };
  const pkgPath = path.join(cwd, 'package.json');
  if (fs.existsSync(pkgPath)) {
    pkgFile = fs.readJsonSync(pkgPath);
  }
  pkgFile.dependencies[name] = version;
  fs.outputJsonSync(pkgPath, pkgFile);
}
654113
public void addDependency(Dependency dependency) {
        Dependency newDep = null;
        String classifier = dependency.getArtifact().getClassifier();
        if ( Const.TEST.equals( classifier ) || Const.TEST_JAR.equals( classifier ) ) {
            ArtifactType artifactType = new DefaultArtifactType( Const.TEST_JAR, Const.JAR, Const.TEST_JAR, null );
            
            Artifact artifact = dependency.getArtifact();
            
            artifact = new DefaultArtifact( artifact.getGroupId(), artifact.getArtifactId(),
                    null, Const.JAR, artifact.getBaseVersion(), artifactType );
            newDep =  new Dependency(artifact, dependency.getScope());
        } else {
            newDep = dependency;
        }
        dependencies.add(newDep);
    }
1374960
protected void addExtraPluginDependencies(Set<Artifact> artifacts) throws MojoExecutionException {
        if (extraPluginDependencyArtifactId == null && extendedPluginDependencyArtifactId == null) {
            return;
        }

        Set<Artifact> deps = new HashSet<Artifact>(this.pluginDependencies);
        for (Artifact artifact : deps) {
            // must
            if (artifact.getArtifactId().equals(extraPluginDependencyArtifactId)
                    || artifact.getArtifactId().equals(extendedPluginDependencyArtifactId)) {

                getLog().debug("Adding extra plugin dependency artifact: " + artifact.getArtifactId() + " to classpath");
                artifacts.add(artifact);

                // add the transient dependencies of this artifact
                Set<Artifact> resolvedDeps = resolveExecutableDependencies(artifact);
                for (Artifact dep : resolvedDeps) {
                    getLog().debug("Adding extra plugin dependency artifact: " + dep.getArtifactId() + " to classpath");
                    artifacts.add(dep);
                }
            }
        }
    }