- Java 17 or later
- Maven 3.3.9 or later
When contributing new features to Bacon, it is required to also provide tests, javadoc documentation and a description of the features to our Feature Guide in our website (see the Documentation section for more information).
This helps the core developers have a better idea of what the new features are to maintain the project.
FatalException
support SLF4J style {}
substitution parameters. For example
throw new FatalException( "Unable to detect charset for file {}", jsonFile, exceptionObject );
throw new FatalException( "Internal failure ; replaced {} by {}", old, d );
throw new FatalException( "Unable to parse", exceptionObject );
The JSON option (-o
) is defined as an inherited option in the top level App. In order for implementations to retrieve its value they should extend JSONCommandHandler
which provides a function to return the value:
protected boolean getJsonOutput()
Sometimes it is useful to be able to add an example of how to use a command on top of the basic usage message. This may be
accomplished by using the footer
attribute combined with a predefined constant e.g.
@Command(
name = "get",
description = "Get an artifact by its id",
footer = Constant.EXAMPLE_TEXT + "$ bacon pnc artifact get 10")
public static class Get extends AbstractGetSpecificCommand<Artifact> {
which produces
java -jar cli/target/bacon.jar pnc artifact get -h
Usage: bacon pnc artifact get [-hov] [-p=<configurationFileLocation>] [--profile=<profile>] <id>
Get an artifact by its id
...
Example:
$ bacon pnc artifact get 10
In order to edit the website at https://project-ncl.github.io/bacon checkout the gh-pages
branch.
It is possible to use Jekyll (https://help.github.com/articles/using-jekyll-with-pages) to preview the changes.
Jekyll can be run with jekyll serve --watch -V
and may be installed in Fedora via the rubygem-jekyll
package.
This README's table of contents is generated by tocdown using the following command line:
ruby .../tocdown/toc.rb -b -r -t -d 3 -s -m <markdown-file>