Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md #33

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 15 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ my-awesome-thing-1.2.3-standalone.jar
You can read more about the layout of a One-JAR archive from the official site
[here](http://one-jar.sourceforge.net/).

##Quick Start
## Quick Start
First, you'll want to add the plugin to your build, as in:
```groovy

Expand Down Expand Up @@ -77,14 +77,14 @@ task awesomeFunJar(type: OneJar) {
}
```

##Advanced Features
## Advanced Features
The current incarnation of the `gradle-one-jar` plugin exists as a highly
configurable Gradle task implementation built as an extension of the built-in
`Jar` task. The following is a non-exhaustive list of some of the more advanced
features that the plugin can perform to meet the varying needs of deploying
standardized artifacts.

###Selectable One-JAR version
### Selectable One-JAR version
By default, the `one-jar-boot` version used is the stable
`one-jar-boot-0.97.jar` which is available from the One-JAR homepage (last
updated 2012-08-15). However, if you'd prefer to use the latest development
Expand All @@ -98,7 +98,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Bring your own One-JAR version
### Bring your own One-JAR version
You can also use your own customized version of a `one-jar-boot` jar by using
the oneJarConfiguration setting, as in the following that assumes your root
project directory contains the jar at
Expand All @@ -120,7 +120,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Use custom configuration for dependencies
### Use custom configuration for dependencies
By default, the plugin uses the current project's `runtime` configuration to
resolve which dependencies are to be included in the final One-JAR archive. If
you would rather use your own custom configuration, you can set it as follows in
Expand Down Expand Up @@ -149,7 +149,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Custom MANIFEST.MF entries
### Custom MANIFEST.MF entries
By default, the MANIFEST.MF added to the final One-JAR archive contains only the
bare minimum number of attributes expected for `one-jar-boot` to behave
correctly. You can add your own custom attributes to the `manifest` property of
Expand All @@ -165,7 +165,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Merge base `Jar` task MANIFEST.MF entries
### Merge base `Jar` task MANIFEST.MF entries
If you just want all of the MANIFEST.MF entries that are present in your
project's `Jar` task to be merged with the default entries needed for
`one-jar-boot` in the final archive, then you can do so with:
Expand All @@ -177,7 +177,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Add your own custom root MANIFEST.MF
### Add your own custom root MANIFEST.MF
If you just want total control over the MANIFEST.MF being used in the final
One-JAR archive, you can override the MANIFEST.MF entry and instead provide your
own custom manifest file with the following:
Expand All @@ -200,7 +200,7 @@ One-Jar-Confirm-Expand: false
Created-By: rholder
```

###Add native libraries
### Add native libraries
Files added to the `/binlib` directory within an archive get expanded to a
temporary directory on startup, and the One-JAR JarClassLoader loads them
automatically. To get your own native library files included in your archive,
Expand All @@ -213,7 +213,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Add any files to the root archive
### Add any files to the root archive
If you just want to be able to drop arbitrary files into the root of the
generated archive, then you can specify a directory (which will also include its
children) to be copied over the top of the the existing files with:
Expand All @@ -225,7 +225,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Framework ClassLoader customizations
### Framework ClassLoader customizations
[Spring](http://www.springsource.org/), [Guice](https://code.google.com/p/google-guice/),
and even [JavaFX](http://docs.oracle.com/javafx/)'s [FXML](http://docs.oracle.com/javafx/2/api/javafx/fxml/doc-files/introduction_to_fxml.html)
make certain assumptions about class loading that may not hold when bundling
Expand All @@ -243,7 +243,7 @@ task awesomeFunJar(type: OneJar) {
}
```

###Override the base Jar task
### Override the base Jar task
By default, the current project's `Jar` task (which is made available when
applying the `java` plugin and exposed as `jar`) is where a `OneJar` task pulls
its raw compiled class and resource information to create the `main/main.jar`
Expand All @@ -267,7 +267,7 @@ having to worry about customizations for specific independent `Jar`
configurations since they could be made to explicitly include whichever build
was necessary.

##Building from source
## Building from source
The `gradle-one-jar` build plugin uses a [Gradle](http://gradle.org)-based build system. In the instructions
below, [`./gradlew`](http://vimeo.com/34436402) is invoked from the root of the source tree and serves as
a cross-platform, self-contained bootstrap mechanism for the build. The only
Expand All @@ -282,7 +282,7 @@ prerequisites are [Git](https://help.github.com/articles/set-up-git) and JDK 1.6
### install all jars into your local Maven cache
`./gradlew install`

##License
## License
The `gradle-one-jar` build plugin is released under version 2.0 of the
[Apache License](http://www.apache.org/licenses/LICENSE-2.0). Distributions
built with this plugin are subject to the terms set forth
Expand All @@ -291,7 +291,7 @@ The One-JAR license is a BSD-style license. Compliance with this license is
assured by including the one-jar-license.txt file in the One-JAR archive, which
this plugin does automatically.

##Contributors
## Contributors
* Jochen Schalanda (joschi)
* Christian S. (squiddle)
* Ben Manes (ben-manes)
Expand Down