javascript:titanium-prepare-package

Full name:

org.codehaus.mojo.javascript:javascript-maven-plugin:1.1-softec:titanium-prepare-package

Description:

This goal strips and compress the source scripts in order to create the distribution package.

Attributes:

  • Requires a Maven project to be executed.
  • Binds by default to the lifecycle phase: package.

Required Parameters

Name Type Since Description
localRepository ArtifactRepository - The local repository
platform String - The platform for which the code should be compiled. android, iphone, ipad, universal

Optional Parameters

Name Type Since Description
compressedDirectory File - The output directory of the compressed javascript files.
Default value is: ${project.build.outputDirectory}.
compressor String - The compressor to used. Either "shrinksafe", "yahooui" or "jsmin" for default compressor, or a custom one provided as an artifact in repo org.codehaus.mojo.javascript:[xxx]-compressor.
Default value is: jsmin.
excludes String[] - Exclusion patterns
executeMode String -

The package execution mode.

Allow the execution of the package on an emulator/device.

Values are:

none
Do not execute. (Default value)
virtual
Execute on an emulator whose settings are specified in TitaniumPackageMojo.virtualDevice.
device
Execute on a connected device.

Default value is: none.
forceCompress boolean - Force compression even if not in "none" executeMode.
Default value is: false.
includes String[] - Inclusion patterns
languageVersion int - JS Language version (130 for JS 1.3)
Default value is: 130.
optimizationLevel int - Optimization level, from 0 to 9
Default value is: 9.
remoteRepositories List - The remote repositories declared in the pom.
scriptClassifier String - optional extension for the compressed artifact. Example "compressed"
scriptsDir String - The name of the script directory.

This parameter is optional it defaults to platform-scripts


scriptsDirectory File - The intput directory for the source javascript files.
Default value is: ${project.build.outputDirectory}.
skipStats boolean - Don't display compression stats
strip String - A special token to recognize lines to be removed from scripts (debugging code).
strippedDirName String - The name of the stripped directory.

This parameter is optional, it defaults to platform-stripped


strippedDirectory File - The output directory of the compressed javascript files.
Default value is: ${project.build.directory}/stripped.
strips String[] - A list of special token to recognize lines to be removed from scripts (debugging code).

Parameter Details

compressedDirectory:

The output directory of the compressed javascript files.
  • Type: java.io.File
  • Required: No
  • Default: ${project.build.outputDirectory}

compressor:

The compressor to used. Either "shrinksafe", "yahooui" or "jsmin" for default compressor, or a custom one provided as an artifact in repo org.codehaus.mojo.javascript:[xxx]-compressor.
  • Type: java.lang.String
  • Required: No
  • Default: jsmin

excludes:

Exclusion patterns
  • Type: java.lang.String[]
  • Required: No

executeMode:

The package execution mode.

Allow the execution of the package on an emulator/device.

Values are:

none
Do not execute. (Default value)
virtual
Execute on an emulator whose settings are specified in TitaniumPackageMojo.virtualDevice.
device
Execute on a connected device.
  • Type: java.lang.String
  • Required: No
  • Expression: ${executeMode}
  • Default: none

forceCompress:

Force compression even if not in "none" executeMode.
  • Type: boolean
  • Required: No
  • Expression: ${forceCompress}
  • Default: false

includes:

Inclusion patterns
  • Type: java.lang.String[]
  • Required: No

languageVersion:

JS Language version (130 for JS 1.3)
  • Type: int
  • Required: No
  • Default: 130

localRepository:

The local repository
  • Type: org.apache.maven.artifact.repository.ArtifactRepository
  • Required: Yes
  • Expression: ${localRepository}

optimizationLevel:

Optimization level, from 0 to 9
  • Type: int
  • Required: No
  • Default: 9

platform:

The platform for which the code should be compiled. android, iphone, ipad, universal
  • Type: java.lang.String
  • Required: Yes
  • Expression: ${platform}

remoteRepositories:

The remote repositories declared in the pom.
  • Type: java.util.List
  • Required: No
  • Expression: ${project.pluginArtifactRepositories}

scriptClassifier:

optional extension for the compressed artifact. Example "compressed"
  • Type: java.lang.String
  • Required: No

scriptsDir:

The name of the script directory.

This parameter is optional it defaults to platform-scripts

  • Type: java.lang.String
  • Required: No

scriptsDirectory:

The intput directory for the source javascript files.
  • Type: java.io.File
  • Required: No
  • Default: ${project.build.outputDirectory}

skipStats:

Don't display compression stats
  • Type: boolean
  • Required: No

strip:

A special token to recognize lines to be removed from scripts (debugging code).
  • Type: java.lang.String
  • Required: No

strippedDirName:

The name of the stripped directory.

This parameter is optional, it defaults to platform-stripped

  • Type: java.lang.String
  • Required: No

strippedDirectory:

The output directory of the compressed javascript files.
  • Type: java.io.File
  • Required: No
  • Default: ${project.build.directory}/stripped

strips:

A list of special token to recognize lines to be removed from scripts (debugging code).
  • Type: java.lang.String[]
  • Required: No