Get the directory where the compiled jasper reports should be put.

@param configuration the configuration for the current app.
325733
public final File getJasperCompilation(final Configuration configuration) {
        File jasperCompilation = new File(getWorking(configuration), "jasper-bin");
        createIfMissing(jasperCompilation, "Jasper Compilation");
        return jasperCompilation;
    }
1183932
def getConfigDirectory():
		
		if platform.system() == 'Windows':
			return os.path.join(os.environ['APPDATA'], 'ue4cli')
		else:
			return os.path.join(os.environ['HOME'], '.config', 'ue4cli')
307424
protected org.apache.commons.configuration.Configuration getApplicationConfiguration() {
        try {
            return ApplicationProperties.get();
        } catch (AtlasException e) {
            LOG.warn("Error reading application configuration", e);
        }
        return null;
    }
1075724
@VisibleForTesting
  void deployConfig(String filename, DeployProjectConfigurationConfiguration configuration)
      throws AppEngineException {
    Preconditions.checkNotNull(configuration);
    Preconditions.checkNotNull(configuration.getAppEngineDirectory());

    Path deployable = configuration.getAppEngineDirectory().resolve(filename);
    Preconditions.checkArgument(
        Files.isRegularFile(deployable), deployable.toString() + " does not exist.");

    List<String> arguments = new ArrayList<>();
    arguments.add("app");
    arguments.add("deploy");
    arguments.add(deployable.toAbsolutePath().toString());
    arguments.addAll(GcloudArgs.get("server", configuration.getServer()));
    arguments.addAll(GcloudArgs.get("project", configuration.getProjectId()));

    try {
      runner.run(arguments, null);
    } catch (ProcessHandlerException | IOException ex) {
      throw new AppEngineException(ex);
    }
  }
1192410
public String getAppServerDefaultDeploymentDir() throws Exception {
        final String[] addressArr = { SUBSYSTEM, DEPLOYMENT_SCANNER, SCANNER, "default" };
        final Address address = Address.root().add(addressArr);
        final ModelNode resourceAttributes = readResource(address);

        if (resourceAttributes == null) {
            return null; // there is no default scanner
        }

        final String path = resourceAttributes.get("path").asString();
        String relativeTo = null;
        if (resourceAttributes.hasDefined("relative-to")) {
            relativeTo = resourceAttributes.get("relative-to").asString();
        }

        // path = the actual filesystem path to be scanned. Treated as an absolute path,
        //        unless 'relative-to' is specified, in which case value is treated as relative to that path.
        // relative-to = Reference to a filesystem path defined in the "paths" section of the server
        //               configuration, or one of the system properties specified on startup.
        //               NOTE: here we will assume that if specified, it is a system property name.

        if (relativeTo != null) {
            String syspropValue = System.getProperty(relativeTo);
            if (syspropValue == null) {
                throw new IllegalStateException("Cannot support relative-to that isn't a sysprop: " + relativeTo);
            }
            relativeTo = syspropValue;
        }

        final File dir = new File(relativeTo, path);
        return dir.getAbsolutePath();
    }
1113242
function(config) {
    var directory = null;

    if(config.workingDir) {
       directory = path.join(config.workingDir, 'level'); 
    } else {
        throw Errors.invalidConfig('Invalid configuration. Working directory not defined.');
    }
    
    return directory;
}
1049362
static String scanConfigFile(String dirPath) throws ConfigurationException {

        String filePath = dirPath + File.separator + CONFIG_FILE_NAME + ".";

        String fullFilePath;
        // Scan for Yaml file
        if (AuditUtil.isFileExists(filePath + YML_EXTENTION)) {
            fullFilePath = filePath + YML_EXTENTION;
        } else if (AuditUtil.isFileExists(filePath + YAML_EXTENTION)) {
            fullFilePath = filePath + YAML_EXTENTION;
        } else if (AuditUtil.isFileExists(filePath + XML_EXTENTION)) {
            // Scan for XML file
            fullFilePath = filePath + XML_EXTENTION;
        } else {
            // Default configuratin file
            fullFilePath = filePath + YML_EXTENTION;
            generateConfigFile(fullFilePath);
        }
        return fullFilePath;
    }
834177
public static void initDefaultsFromConfiguration(Configuration configuration) {
		final boolean overwrite = configuration.getBoolean(CoreOptions.FILESYTEM_DEFAULT_OVERRIDE);
	
		DEFAULT_WRITE_MODE = overwrite ? WriteMode.OVERWRITE : WriteMode.NO_OVERWRITE;
		
		final boolean alwaysCreateDirectory = configuration.getBoolean(CoreOptions.FILESYSTEM_OUTPUT_ALWAYS_CREATE_DIRECTORY);
	
		DEFAULT_OUTPUT_DIRECTORY_MODE = alwaysCreateDirectory ? OutputDirectoryMode.ALWAYS : OutputDirectoryMode.PARONLY;
	}
983280
private void addSourceRoot (final File directory)
  {
    if (this.project != null)
    {
      getLog ().debug ("Adding compile source root: " + directory);
      this.project.addCompileSourceRoot (directory.getAbsolutePath ());
    }
  }
213007
public static DocFile createFileForDirectory(Configuration configuration, String file) {
        return DocFileFactory.getFactory(configuration).createFileForDirectory(file);
    }
542359
public void setCompileDirectory(String directory) {
        if (directory != null && directory.trim().length() > 0) {
            File file = new File(directory);
            if (file.exists() || file.mkdirs()) {
                this.compileDirectory = file;
            }
        }
    }
1150126
static synchronized DocFileFactory getFactory(Configuration configuration) {
        DocFileFactory f = factories.get(configuration);
        if (f == null) {
            JavaFileManager fm = configuration.getFileManager();
            if (fm instanceof StandardJavaFileManager)
                f = new StandardDocFileFactory(configuration);
            else {
                try {
                    Class<?> pathFileManagerClass =
                            Class.forName("com.sun.tools.javac.nio.PathFileManager");
                    if (pathFileManagerClass.isAssignableFrom(fm.getClass()))
                        f = new PathDocFileFactory(configuration);
                } catch (Throwable t) {
                    throw new IllegalStateException(t);
                }
            }
            factories.put(configuration, f);
        }
        return f;
    }
1204775
public static File findTemplateDirectory( ApplicationTemplate tpl, File configurationDirectory ) {

		StringBuilder sb = new StringBuilder( TEMPLATES );
		sb.append( "/" );
		sb.append( tpl.getName());
		if( ! Utils.isEmptyOrWhitespaces( tpl.getVersion())) {
			sb.append( " - " );
			sb.append( tpl.getVersion());
		}

		return new File( configurationDirectory, sb.toString());
	}
944430
def _directory (self):
        """"""
        if self._filename is None:
            return os.path.join(self._ROOT_DIR, 'config')
        else:
            return os.path.dirname(self._filename)
488510
def _get_config_dir():
    
    if 'SAWTOOTH_HOME' in os.environ:
        return os.path.join(os.environ['SAWTOOTH_HOME'], 'etc')

    if os.name == 'nt':
        base_dir = \
            os.path.dirname(os.path.dirname(os.path.abspath(sys.argv[0])))
        return os.path.join(base_dir, 'conf')

    return '/etc/sawtooth'
954010
public static HierarchicalConfiguration getHierarchicalConfiguration(final Configuration configuration) {
        if (configuration instanceof CompositeConfiguration) {
            final CompositeConfiguration compositeConfig = (CompositeConfiguration) configuration;
            for (int i = 0; i < compositeConfig.getNumberOfConfigurations(); i++) {
                if (compositeConfig.getConfiguration(i) instanceof HierarchicalConfiguration) {
                    return (HierarchicalConfiguration) compositeConfig.getConfiguration(i);
                }
            }
        }
        // maybe I need to send a runtime exception ??
        // throw new
        // ConfigurationRuntimeException("no hierarchical configuration was defined");
        return null;
    }
904014
private void completeFilesystem(ConfigurationBuilder builder, Configuration configuration)
    {
        PersistenceConfigurationBuilder persistence = builder.persistence();

        if (containsIncompleteFileLoader(configuration)) {
            for (StoreConfigurationBuilder<?, ?> store : persistence.stores()) {
                if (store instanceof SingleFileStoreConfigurationBuilder) {
                    SingleFileStoreConfigurationBuilder singleFileStore = (SingleFileStoreConfigurationBuilder) store;

                    singleFileStore.location(createTempDir());
                }
            }
        }
    }