• Intro Headers Instructions Macros Commands
  • Fork me on GitHub
    • Introduction
    • How to install bnd
    • Guided Tour
    • Guided Tour Workspace & Projects
    • Concepts
    • Best practices
    • Build
    • Project Setup
    • Generating JARs
    • Versioning
    • Baselining
    • Service Components
    • Metatype
    • Contracts
    • Bundle Annotations
    • Accessor Properties
    • SPI Annotations
    • Resolving Dependencies
    • Launching
    • Startlevels
    • Testing
    • Testing with Launchpad
    • Packaging Applications
    • JPMS Libraries
    • Wrapping Libraries to OSGi Bundles
    • Generating Documentation
    • Commands
    • For Developers
    • Tips for Windows users
    • Tools bound to bnd
    • Headers
    • Instruction Reference
    • Instruction Index
    • Macro Reference
    • Macro Index
    • Plugins
    • External Plugins
    • Settings
    • Errors
    • Warnings
    • Frequently Asked Questions
  • Instruction Index

    -augment PARAMETER ( ',' PARAMETER ) *
    Add requirements and capabilities to the resources during resolving.
    -baseline selector
    Control what bundles are enabled for baselining and optionally specify the baseline version or file.
    -baselinerepo qname
    Define the repository to calculate baselining against
    -builderignore PATH-SPEC ( ',' PATH-SPEC ) *
    List of project-relative directories to be ignored by the builder.
    -buildpath PATH
    Provides the class path for building the jar, the entries are references to the repositories.
    -buildrepo repo ( ',' repo ) *
    After building a JAR, release the JAR to the given repositories.
    -bumppolicy
    The policy for the bump command
    -bundleannotations SELECTORS
    Selects the classes that need processing for standard OSGi Bundle annotations.
    -cdiannotations SELECTORS
    Selects the packages that need processing for CDI annotations.
    -check 'ALL' | ( 'IMPORTS' | 'EXPORTS' ) *
    Enable additional checking
    -classpath FILE (',' FILE) *
    Specify additional file based entries (either directories or JAR files) to add to the used classpath.
    -compression DEFLATE | STORE
    Set the compression level for the generated JAR, the default is DEFLATE
    Conditional-Package PACKAGE-SPEC ( ',' PACKAGE-SPEC ) *
    Recursively add packages from the class path when referred and when they match one of the package specifications.
    -conditionalpackage PACKAGE-SPEC ( ',' PACKAGE-SPEC ) *
    Recursively add packages from the class path when referred and when they match one of the package specifications.
    -conduit
    This project is a front to one or more JARs in the file system
    -connection-settings
    Setting up the communications for bnd
    -consumer-policy VERSION-MASK
    Specify the default version bump policy for a consumer when a binary incompatible change is detected.
    -contract
    Establishes a link to a contract and handles the low level details.
    -define-contract
    Define a contract when one cannot be added to the buildpath.
    -dependson SELECTORS
    Add dependencies from the current project to other projects, before this project is built, any project this project depends on will be built first.
    -deploy
    Deploy this project through Deploy plugins (MavenDeploy plugin). Needs work
    -deployrepo
    Deploy this project through Deploy plugins (MavenDeploy plugin). Needs work
    -diffignore SELECTORS
    Manifest header names and resource paths to ignore during baseline comparison.
    -diffpackages SELECTORS
    The names of exported packages to baseline.
    -digests DIGEST ( ',' DIGEST ) *
    Set the digest algorithms to use
    -distro REPO (',' REPO)
    Resolve against pre-defined system capabilities
    -donotcopy
    Set the default filters for file resources that should not be copied.
    -dsannotations-options SELECTORS
    Options for controlling DS annotation processing.
    -dsannotations SELECTORS
    Selects the packages that need processing for standard OSGi DS annotations.
    -eeprofile 'auto' | PROFILE +
    Provides control over what Java 8 profile to use.
    -executable ( rejar= STORE | DEFLATE ) ( ',' strip= matcher ( ',' matcher )* ) ( ',' location= FORMAT )
    Process an executable jar to strip optional directories of the contained bundles, and/or change their compression. The location string can also be calculated from bsn and version
    -export-apiguardian PACKAGE-SPEC, ( ',' PACKAGE-SPEC )*
    Exports the given packages where the the `@API` annotation is found on contained classes.
    -export PATH ( ';' PARAMETER )* ( ',' PATH ( ';' PARAMETER )* )*
    Turns a bndrun file into its deployable format
    -exportcontents PACKAGE-SPEC, ( ',' PACKAGE-SPEC )*
    Exports the given packages but does not try to include them from the class path. The packages should be loaded with alternative means.
    -exportreport report-def ( ',' report-def )*
    Configure a list of reports to be exported.
    -extension
    A plugin that is loaded to its url, downloaded and then provides a header used instantiate the plugin.
    -failok ('true' | 'false')?
    Will ignore any error during building and assume all went ok.
    -fixupmessages SELECTOR ( ';' ( is | replace | restrict ) )* ...
    Fixup errors and warnings.
    -generate srcs ';output=' DIR ( ';' ( system | generate | classpath))* ...
    Generate sources
    -groupid groupId
    Set the default Maven groupId
    -include PATH-SPEC ( ',' PATH-SPEC ) *
    Include a number of files from the file system
    -includepackage PACKAGE-SPEC, ( ',' PACKAGE-SPEC )*
    Include a number of packages from the class path
    -includeresource iclause
    Include resources from the file system
    -invalidfilenames
    Specify file/directory names that should not be used because they are not portable.
    -javaagent BOOLEAN
    Specify if classpath jars with Premain-Class headers are to be used as java agents
    -make
    If a resource is not found, specify a recipe to make it.
    -manifest FILE
    Override manifest calculation and set fixed manifest
    -manifest-name RESOURCE
    Set the resource path to the manifest, for certain standards the manifest has a different name.
    -maven-dependencies* entry ( ',' entry )*
    Configure maven dependency information for the generated pom
    -maven-release ('local'|'remote') ( ',' option )*
    Set the Maven release options for the Maven Bnd Repository
    -maven-scope dependency-scope
    Set the default Maven dependency scope to use when generating dependency information in the generated pom
    -metatype-options SELECTORS
    Restricts the use of Metatype Annotation to a minimum version.
    -metatype CLASS-SPEC ( ',' CLASS-SPEC )*
    Create metatype XML resources in the bundle based on the OCD annotations.
    -namesection RESOURCE-SPEC ( ',' RESOURCE-SPEC ) *
    Create a name section (second part of manifest) with optional property expansion and addition of custom attributes. Patterns not ending with \"/\" target resources. Those ending with \"/\" target packages.
    -nobuildincache BOOLEAN
    Do not use a build in cache for the launcher and JUnit.
    -nobundles BOOLEAN
    Do not build the project.
    -noclassforname BOOLEAN
    Do not add package reference to classes loaded with Class.forName(String).
    -nodefaultversion BOOLEAN
    Do not add a default version to exported packages when no version is present.
    -noee BOOLEAN
    Donot add an automatic requirement on an EE capability based on the class format.
    -noextraheaders BOOLEAN
    Do not add a any extra headers specific for bnd.
    -noimportjava BOOLEAN
    Do not import java.* packages.
    -nojunit BOOLEAN
    Indicate that this project does not have JUnit tests
    -nojunitosgi BOOLEAN
    Indicate that this project does not have JUnit OSGi tests
    -nomanifest BOOLEAN
    Do not safe the manifest in the JAR.
    -noparallel CATEGORY;task=TASKS
    Prevent Gradle tasks in the same category from executing in parallel.
    -nouses BOOLEAN
    Do not calculate uses directives on package exports or on capabilities.
    -output FILE
    Specify the output directory or file.
    -outputmask TEMPLATE ?
    If set, is used a template to calculate the output file. It can use any macro but the ${@bsn} and ${@version} macros refer to the current JAR being saved. The default is bsn + ".jar".
    -package
    Packaging options
    -pedantic BOOLEAN
    Warn about things that are not really wrong but still not right.
    -plugin.* plugin-def ( ',' plugin-def )*
    Load plugins and their parameters.
    -pluginpath* PARAMETERS
    Define JARs to be loaded in the local classloader for plugins.
    -pom BOOLEAN | PROPERTIES
    Generate a maven pom in the JAR
    -prepare makespec ( ',' makespec )*
    Execute a number of shell commands before every build (might not work on Windows)
    -preprocessmatchers SELECTOR
    Specify which files can be preprocessed
    -privatepackage PACKAGE-SPEC
    Specify the private packages, these packages are included from the class path. Alternative to Private-Package, this version is not included in the manifest.
    -profile KEY
    Sets a prefix that is used when a variable is not found, it is then re-searched under "[<[profile]>]<[key]>".
    -provider-policy VERSION-MASK
    Specify the default version bump policy for a provider when a binary incompatible change is detected.
    -releaserepo* NAME ( ',' NAME ) *
    Define the names of the repositories to use for a release
    -remoteworkspace (true|false)
    Enable the workspace to server remote requests from the local system, needed for Launchpad
    -removeheaders KEY-SELECTOR ( '.' KEY-SELECTOR ) *
    Remove matching headers from the manifest.
    -reportconfig plugin-def ( ',' plugin-def )*
    Configure a the content of report.
    -reportnewer BOOLEAN
    Report any entries that were added to the build since the last JAR was made.
    -require-bnd (FILTER ( ',' FILTER )* )?
    The filter can test against 'version', which will contain the Bnd version. If it does not match, Bnd will generate an error.
    -resolve.effective qname (',' qname )
    Set the use effectives for the resolver
    -resolve (manual|auto|beforelaunch|batch)
    Defines when/how resolving is done to calculate the -runbundles
    -resolve.preferences qname ( ',' qname )
    Override the default order and selection of repositories
    -resourceonly BOOLEAN
    Ignores warning if the bundle only contains resources and no classes.
    -runblacklist requirement (',' requirement)
    Blacklist a set of bundles for a resolve operation
    -runbuilds BOOLEAN
    Defines if this should add the bundles build by this project to the -runbundles. For a bndrun file this is default false, for a bnd file this is default true.
    -runbundles* REPO-ENTRY ( ',' REPO-ENTRY )*
    Add additional bundles, specified with their bsn and version like in -buildpath, that are installed and started before the project is run.
    -runee EE
    Define the runtime Execution Environment capabilities, default Java 6.
    -runenv PROPERTIES
    Specify a JDB port on invocation when launched outside a debugger so the debugger can attach later.
    -runframework ( 'none' | 'services' | ANY )?
    Sets the type of framework to run. If 'none', an internal dummy framework is used. Otherwise the Java META-INF/services model is used for the FrameworkFactory interface name.
    -runframeworkrestart BOOLEAN
    Restart the framework in the same VM if the framework is stopped or updated.
    -runfw REPO-ENTRY
    Specify the framework JAR's entry in a repository.
    -runjdb PORT
    Specify a JDB port on invocation when launched outside a debugger so the debugger can attach later.
    -runkeep true | false
    Decides to keep the framework storage directory between launching
    -runnoreferences BOOLEAN
    Do not use the `reference:` URL scheme for installing a bundle in the installer.
    -runpath REPO-ENTRY ( ',' REPO-ENTRY )
    Additional JARs for the remote VM path, should include the framework.
    -runprogramargs
    Additional arguments for the program invokation.
    -runproperties PROPERTIES
    Define system properties for the remote VM.
    -runprovidedcapabilities
    Extra capabilities for a distro resolve
    -runrepos REPO-NAME ( ',' REPO-NAME )*
    Order and select the repository for resolving against. The default order is all repositories in their plugin creation order.
    -runrequires REQUIREMENT ( ',' REQUIREMENT )*
    The root requirements for a resolve intended to create a constellation for the -runbundles.
    -runstartlevel ( order | begin | step )*
    Assign a start level to each run-bundle after resolving
    -runstorage FILE
    Define the directory to use for the framework's work area.
    -runsystemcapabilities* CAPABILITY (',' CAPABILITY )
    Define extra capabilities for the remote VM.
    -runsystempackages* PARAMETERS
    Define extra system packages (packages exported from the remote VM -runpath).
    -runtimeout DURATION
    -runtrace BOOLEAN
    Trace the launched process in detail
    -runvm KEYS
    Additional arguments for the VM invocation. Arguments are added as-is.
    -savemanifest FILE
    Write out the manifest to a separate file after it has been calculated.
    -sign PARAMETERS
    Report any entries that were added to the build since the last JAR was made.
    -snapshot STRING
    String to substitute for "SNAPSHOT" in the bundle version's qualifier
    -sourcepath
    List of directory names that used to find sources.
    -sources BOOLEAN
    Include the source code (if available on the -sourcepath) in the bundle at OSGI-OPT/src
    -stalecheck srcs ';newer=' depends ( ';' ( warning | error | command ))* ...
    Perform a stale check of files and directories before building a jar
    -standalone repo-spec (, repo-spec )
    Disconnects the bndrun file from the workspace and defines its on repositories
    -strict BOOLEAN
    If strict is true, then extra verification is done.
    -sub FILE-SPEC ( ',' FILE-SPEC )*
    Build a set of bnd files that use this bnd file as a basis. The list of bnd file can be specified with wildcards.
    -systemproperties PROPERTIES
    These system properties are set in the local JVM when a workspace is started. This was mainly added to allow one to set JVM options via system properties.
    -testcontinuous BOOLEAN
    Do not exit after running the test suites but keep watching the bundles and rerun the test cases if the bundle is updated.
    -tester REPO-SPEC
    Species the tester (bundle) that is supposed to test the code. The default is biz.aQute.tester
    -testpackages PACKAGE-SPEC ( ',' PACKAGE-SPEC )
    -testpath REPO-SPEC ( ',' REPO-SPEC )
    The specified JARs from a repository are added to the remote JVM's classpath if the JVM is started in test mode in addition to the -runpath JARs.
    -testsources REGEX ( ',' REGEX )*
    Specification to find JUnit test cases by traversing the test src directory and looking for java classes. The default is (.*).java.
    -testunresolved BOOLEAN
    Will execute a JUnit testcase ahead of any other test case that will abort if there are any unresolved bundles.
    -undertest true
    Will be set by the project when it builds a JAR in test mode, intended to be used by plugins.
    -upto VERSION
    Specify the highest compatibility version, will disable any incompatible features added after this version.
    -wab FILE ( ',' FILE )*
    Create a Web Archive Bundle (WAB) or a WAR
    -wablib FILE ( ',' FILE )*
    Specify the libraries that must be included in a Web Archive Bundle (WAB) or WAR.
    -workingset PARAMETER ( ',' PARAMETER ) *
    Group the workspace into different working sets
    • GitHub