Expansion Configuration

Options for a single expand action

Some options for expansion are specific to the situation. These option can be provided during the call to the command line interface.

setting description cli option
clean directory clean target directory before expansion --clean
verbose print more information during expand --verbose

It may be also be useful to somehow add the possibility to set personal defaults for these options. That way, they do not have to be passed with each specific call.

Application specific

Applications each have settings specific to that application.

setting description
application path directory for the application folder
component path directory for component path, is extended with the path to the baseComponents
expansion directory target directory for the expanded project
use component file read model based on full component files instead of directory
settings paths path to the different settings files used in the application instance
expander configuration configure project specific expanders
exclude default expanders exclude all default expanders to create a clean project with custom expanders

These settings could be supplied through a configuration file that is placed at a specific location in the project’s file structure. The Prime Radiant can supply these settings from it’s own configuration.

A configuration file would look something like:

<applicationExpansion name="tutorialApp">
  <applicationPath>
    <applicationDirectory>C:/NSF-3.0/workspace/tutorialApp</applicationDirectory>
  </applicationPath>
  <componentPath>
    <componentDirectory>C:/NSF-3.0/workspace/tutorialApp</componentDirectory>
    <componentDirectory>C:/NSF-3.0/workspace/descriptors</componentDirectory>
  </componentPath>
  <expansionDirectory>C:/NSF-3.0/workspace/expansions</expansionDirectory>
  <settingsPath>
    <settingsDirectory>C:/NSF-3.0/repositories/settings</settingsDirectory>
  </settingsPath>
  <expanderConfig>
    <expanderConfigFile>C:/NSF-3.0/workspace/tutorialApp/custom-expanders.xml</expanderConfigFile>
  </expanderConfig>
  <excludeDefaultExpanders value="false"/>
  <useComponentFile value="false"/>
</applicationExpansion>

In order to keep this configuration in sync with the Prime Radiant, an import and export of these settings is required through the Prime Radiant.

Global settings

Some settings are global settings that will be the same for each application. Most of these settings boil down to how the NSF installation is structured.

setting description
library dependency file can be used to extend/overwrite the list of dependencies of the application
repositories directory path to the repositories directory
infrastructure directory path to the infrastructure directory (only required by ANT)
expander configuration configure additional ‘installed’ expanders

This setting is implicit in the Prime Radiant data, but should also be available for expand outside of the Prime Radiant:

<nsfInstallation>
  <repositoriesDir>C:/NSF-3.0/repositories</repositoriesDir>
  <infrastructureDir>C:/NSF-3.0/infrastructure</infrastructureDir>
  <libDependencyPath>
    <libDependencyFile>C:/NSF-3.0/repositories/conf/libDeps_latest.yaml</libDependencyFile>
  </libDependencyPath>
  <expanderConfig>
    <expanderConfigFile>C:/NSF-3.0/repositories/ext/green/green-expanders.xml</expanderConfigFile>
  </expanderConfig>
</nsfInstallation>

Loading workflow

Expansion config loading