mirror of
https://github.com/jlengrand/jreleaser.github.io.git
synced 2026-03-10 08:31:25 +00:00
436 lines
12 KiB
Plaintext
436 lines
12 KiB
Plaintext
= Project
|
|
|
|
Defines general information about the project.
|
|
|
|
include::partial$legend.adoc[]
|
|
|
|
[tabs]
|
|
====
|
|
YAML::
|
|
+
|
|
[source,yaml]
|
|
[subs="+macros"]
|
|
----
|
|
# icon:exclamation-triangle[]
|
|
project:
|
|
# The name of the project.
|
|
# icon:exclamation-triangle[]
|
|
name: app
|
|
|
|
# The version to be released.
|
|
# May define a `JRELEASER_PROJECT_VERSION` environment variable instead.
|
|
# icon:exclamation-triangle[] icon:eye-slash[]
|
|
version: 1.0.0
|
|
|
|
# A regex to determine if the project version is snapshot
|
|
# May define a `JRELEASER_SNAPSHOT_PATTERN` environment variable instead.
|
|
# icon:dot-circle[] icon:eye-slash[]
|
|
snapShotPattern: .*-SNAPSHOT
|
|
|
|
# A short description (60 chars max).
|
|
# icon:exclamation-triangle[]
|
|
description: My awesome app
|
|
|
|
# A more thorough explanation of the project's capabilities.
|
|
# May use markdown syntax.
|
|
# If left unspecified, will use the value of `description`.
|
|
# icon:dot-circle[]
|
|
longDescription: |
|
|
My Awesome app is the bees knees
|
|
|
|
# The project's website.
|
|
# icon:exclamation-triangle[]
|
|
website: pass:[https://acme.com/app]
|
|
|
|
# A list of author names.
|
|
# icon:exclamation-triangle[]
|
|
authors:
|
|
- Duke
|
|
|
|
# A list of tags.
|
|
# icon:dot-circle[]
|
|
tags:
|
|
- cli
|
|
- awesome
|
|
|
|
# The project's license.
|
|
# It's recommended to use a valid SPDX identifier if the project is Open Source.
|
|
# See link:https://spdx.org/licenses[].
|
|
# icon:exclamation-triangle[]
|
|
license: Apache-2.0
|
|
|
|
# Additional properties used when evaluating templates.
|
|
# icon:dot-circle[]
|
|
extraProperties:
|
|
# Key will be capitalized and prefixed with `project`, i.e, `projectFoo`.
|
|
foo: bar
|
|
|
|
# Required if there are configured distributions.
|
|
# icon:dot-circle[]
|
|
java:
|
|
# Maven coordinates: groupId.
|
|
# Inherited by distributions if they do not define a value for it.
|
|
# icon:exclamation-triangle[]
|
|
groupId: com.acme
|
|
|
|
# Maven coordinates: artifactId.
|
|
# If undefined, will use ${project.name}.
|
|
# Inherited by distributions if they do not define a value for it.
|
|
# icon:exclamation-triangle[]
|
|
artifactId: app
|
|
|
|
# The minimum Java version required by consumers to run the application.
|
|
# icon:exclamation-triangle[]
|
|
version: 8
|
|
|
|
# The application's entry point.
|
|
# icon:dot-circle[]
|
|
mainClass: com.acme.Main
|
|
|
|
# Identifies the project as being member of a multi-project build.
|
|
# Defaults to `false`.
|
|
# icon:dot-circle[]
|
|
multiProject : false
|
|
----
|
|
JSON::
|
|
+
|
|
[source,json]
|
|
[subs="+macros"]
|
|
----
|
|
{
|
|
// icon:exclamation-triangle[]
|
|
"project": {
|
|
// The name of the project.
|
|
// icon:exclamation-triangle[]
|
|
"name": "app",
|
|
|
|
// The version to be released.
|
|
// May define a `JRELEASER_PROJECT_VERSION` environment variable instead.
|
|
// icon:exclamation-triangle[] icon:eye-slash[]
|
|
"version": "1.0.0",
|
|
|
|
// A regex to determine if the project version is snapshot
|
|
// May define a `JRELEASER_SNAPSHOT_PATTERN` environment variable instead.
|
|
// icon:dot-circle[] icon:eye-slash[]
|
|
"snapShotPattern": ".*-SNAPSHOT",
|
|
|
|
// A short description (60 chars max).
|
|
// icon:exclamation-triangle[]
|
|
"description": "My awesome app",
|
|
|
|
// A more thorough explanation of the project's capabilities.
|
|
// May use markdown syntax.
|
|
// If left unspecified, will use the value of `description`.
|
|
// icon:dot-circle[]
|
|
"longDescription": "My Awesome app is the bees knees",
|
|
|
|
// The project's website.
|
|
// icon:exclamation-triangle[]
|
|
"website": "pass:[https://acme.com/app]",
|
|
|
|
// A list of author names.
|
|
// icon:exclamation-triangle[]
|
|
"authors": [
|
|
"Duke"
|
|
],
|
|
|
|
// A list of tags.
|
|
// icon:dot-circle[]
|
|
"tags": [
|
|
"cli",
|
|
"awesome"
|
|
],
|
|
|
|
// The project's license.
|
|
// It's recommended to use a valid SPDX identifier if the project is Open Source.
|
|
// See link:https://spdx.org/licenses[].
|
|
// icon:exclamation-triangle[]
|
|
"license": "Apache-2.0",
|
|
|
|
// Additional properties used when evaluating templates.
|
|
// icon:dot-circle[]
|
|
"extraProperties": {
|
|
// Key will be capitalized and prefixed with `project`, i.e, `projectFoo`.
|
|
"foo": "bar"
|
|
},
|
|
|
|
// Required if there are configured distributions.
|
|
// icon:dot-circle[]
|
|
"java": {
|
|
// Maven coordinates: groupId.
|
|
// Inherited by distributions if they do not define a value for it.
|
|
// icon:exclamation-triangle[]
|
|
"groupId": "com.acme",
|
|
|
|
// Maven coordinates: artifactId.
|
|
// If undefined, will use ${project.name}.
|
|
// Inherited by distributions if they do not define a value for it.
|
|
// icon:exclamation-triangle[]
|
|
"artifactId": "app",
|
|
|
|
// The minimum Java version required by consumers to run the application.
|
|
// icon:exclamation-triangle[]
|
|
"version": "8",
|
|
|
|
// The application's entry point.
|
|
// icon:dot-circle[]
|
|
"mainClass": "com.acme.Main",
|
|
|
|
// Identifies the project as being member of a multi-project build.
|
|
// Defaults to `false`.
|
|
// icon:dot-circle[]
|
|
"multiProject": false
|
|
}
|
|
}
|
|
}
|
|
----
|
|
Maven::
|
|
+
|
|
[source,xml]
|
|
[subs="+macros,verbatim"]
|
|
----
|
|
<jreleaser>
|
|
<!--
|
|
icon:exclamation-triangle[]
|
|
-->
|
|
<project>
|
|
<!--
|
|
The name of the project.
|
|
icon:exclamation-triangle[]
|
|
-->
|
|
<name>app</name>
|
|
|
|
<!--
|
|
The version to be released.
|
|
If undefined, will use ${project.version} from Maven.
|
|
May define a `JRELEASER_PROJECT_VERSION` environment variable instead.
|
|
icon:exclamation-triangle[] icon:eye-slash[]
|
|
-->
|
|
<version>1.0.0</version>
|
|
|
|
<!--
|
|
A regex to determine if the project version is snapshot
|
|
May define a `JRELEASER_SNAPSHOT_PATTERN` environment variable instead.
|
|
icon:dot-circle[] icon:eye-slash[]
|
|
-->
|
|
<snapShotPattern>.*-SNAPSHOT</snapShotPattern>
|
|
|
|
<!--
|
|
A short description (60 chars max).
|
|
If undefined, will use ${project.description} from Maven.
|
|
icon:exclamation-triangle[]
|
|
-->
|
|
<description>My awesome app</description>
|
|
|
|
<!--
|
|
A more thorough explanation of the project's capabilities.
|
|
May use markdown syntax.
|
|
If left unspecified, will use the value of `description`.
|
|
icon:dot-circle[]
|
|
-->
|
|
<longDescription>
|
|
My Awesome app is the bees knees
|
|
</longDescription>
|
|
|
|
<!--
|
|
The project's website.
|
|
If undefined, will use ${project.url} from Maven.
|
|
icon:exclamation-triangle[]
|
|
-->
|
|
<website>pass:[https://acme.com/app]</website>
|
|
|
|
<!--
|
|
A list of author names.
|
|
If undefined, will use ${project.developers} from Maven, looking for
|
|
matches of <role>author</role>
|
|
icon:exclamation-triangle[]
|
|
-->
|
|
<authors>
|
|
<author>Duke</author>
|
|
</authors>
|
|
|
|
<!--
|
|
A list of tags.
|
|
icon:dot-circle[]
|
|
-->
|
|
<tags>
|
|
<tag>cli</tag>
|
|
<tag>awesome</tag>
|
|
</tags>
|
|
|
|
<!--
|
|
The project's license.
|
|
If undefined, will use ${project.licenses} from Maven.
|
|
It's recommended to use a valid SPDX identifier if the project is Open Source.
|
|
See link:https://spdx.org/licenses[].
|
|
icon:exclamation-triangle[]
|
|
-->
|
|
<license>Apache-2.0</license>
|
|
|
|
<!--
|
|
Additional properties used when evaluating templates.
|
|
icon:dot-circle[]
|
|
-->
|
|
<extraProperties>
|
|
<!--
|
|
Key will be capitalized and prefixed with `project`, i.e, `projectFoo`.
|
|
-->
|
|
<foo>bar</foo>
|
|
</extraProperties>
|
|
|
|
<!--
|
|
Required if there are configured distributions.
|
|
icon:dot-circle[]
|
|
-->
|
|
<java>
|
|
<!--
|
|
Maven coordinates: groupId.
|
|
Inherited by distributions if they do not define a value for it.
|
|
If undefined, will use ${project.groupId} from Maven.
|
|
icon:dot-circle[]
|
|
-->
|
|
<groupId>com.acme</groupId>
|
|
|
|
<!--
|
|
Maven coordinates: artifactId.
|
|
Inherited by distributions if they do not define a value for it.
|
|
If undefined, will use ${project.artifactId} from Maven.
|
|
icon:dot-circle[]
|
|
-->
|
|
<artifactId>app</artifactId>
|
|
|
|
<!--
|
|
The minimum Java version required by consumers to run the application.
|
|
If undefined, will determined by reading the following Maven properties:
|
|
- maven.compiler.release
|
|
- maven.compiler.target
|
|
- maven.compiler.source
|
|
- project.compilerRelease
|
|
- System.getProperty("java.version")
|
|
icon:dot-circle[]
|
|
-->
|
|
<version>8</version>
|
|
|
|
<!--
|
|
The application's entry point.
|
|
icon:dot-circle[]
|
|
-->
|
|
<mainClass>com.acme.Main</mainClass>
|
|
|
|
<!--
|
|
Identifies the project as being member of a multi-project build.
|
|
Defaults to `false`.
|
|
icon:dot-circle[]
|
|
-->
|
|
<multiProject>false</multiProject>
|
|
</java>
|
|
</project>
|
|
</jreleaser>
|
|
----
|
|
Gradle::
|
|
+
|
|
[source,groovy]
|
|
[subs="+macros"]
|
|
----
|
|
jreleaser {
|
|
project {
|
|
// The name of the project.
|
|
// icon:exclamation-triangle[]
|
|
name = 'app'
|
|
|
|
// The version to be released.
|
|
// If undefined, will use ${project.version} from Gradle.
|
|
// May define a `JRELEASER_PROJECT_VERSION` environment variable instead.
|
|
// icon:exclamation-triangle[] icon:eye-slash[]
|
|
version = '1.0.0'
|
|
|
|
// A regex to determine if the project version is snapshot
|
|
// May define a `JRELEASER_SNAPSHOT_PATTERN` environment variable instead.
|
|
// icon:dot-circle[] icon:eye-slash[]
|
|
snapShotPattern = '.*-SNAPSHOT'
|
|
|
|
// A short description (60 chars max).
|
|
// icon:exclamation-triangle[]
|
|
description = 'My awesome app'
|
|
|
|
// A more thorough explanation of the project's capabilities.
|
|
// May use markdown syntax.
|
|
// If left unspecified, will use the value of `description`.
|
|
// icon:dot-circle[]
|
|
longDescription = 'My Awesome app is the bees knees'
|
|
|
|
// The project's website.
|
|
// icon:exclamation-triangle[]
|
|
website = 'pass:[https://acme.com/app]'
|
|
|
|
// A list of author names.
|
|
// icon:exclamation-triangle[]
|
|
authors = ['Duke']
|
|
|
|
// A list of tags.
|
|
// icon:dot-circle[]
|
|
tags = ['cli', 'awesome']
|
|
|
|
// The project's license.
|
|
// It's recommended to use a valid SPDX identifier if the project is Open Source.
|
|
// See link:https://spdx.org/licenses[].
|
|
// icon:exclamation-triangle[]
|
|
license = 'Apache-2.0'
|
|
|
|
// Additional properties used when evaluating templates.
|
|
// Key will be capitalized and prefixed with `project`, i.e, `projectFoo`.
|
|
// icon:dot-circle[]
|
|
extraProperties.put('foo', 'bar')
|
|
|
|
// Required if there are configured distributions.
|
|
// icon:dot-circle[]
|
|
java {
|
|
// Maven coordinates: groupId.
|
|
// Inherited by distributions if they do not define a value for it.
|
|
// If undefined, will use ${project.group} from Gradle.
|
|
// icon:dot-circle[]
|
|
groupId = 'com.acme'
|
|
|
|
// Maven coordinates: artifactId.
|
|
// Inherited by distributions if they do not define a value for it.
|
|
// If undefined, will use ${project.name} from Gradle.
|
|
// icon:dot-circle[]
|
|
artifactId = 'app'
|
|
|
|
// The minimum Java version required by consumers to run the application.
|
|
// If undefined, will determined by reading the following Gradle properties:
|
|
// - project.targetCompatibility
|
|
// - project.compilerRelease
|
|
// - JavaVersion.current()
|
|
// icon:dot-circle[]
|
|
version = '8'
|
|
|
|
// The application's entry point.
|
|
// icon:dot-circle[]
|
|
mainClass = 'com.acme.Main'
|
|
|
|
// Identifies the project as being member of a multi-project build.
|
|
// Defaults to `false`.
|
|
// If undefined, will be determine based on the Gradle setup.
|
|
// icon:dot-circle[]
|
|
multiProject = false
|
|
}
|
|
}
|
|
}
|
|
----
|
|
====
|
|
|
|
When the `link:https://kordamp.org/kordamp-gradle-plugins/[org.kordamp.gradle.project]` is
|
|
used in combination with Gradle then the following properties will be automatically mapped if
|
|
there were not defined in the `jreleaser` DSL block:
|
|
|
|
[%header, cols="<1,<1", width="100%"]
|
|
|===
|
|
| JReleaser | Kordamp
|
|
| description | config.info.description
|
|
| website | config.info.links.website
|
|
| authors | config.info.authors
|
|
| tags | config.info.tags
|
|
| license | config.info.licenses
|
|
|===
|