Skip to content

Commit f7fa54a

Browse files
committed
docs: tag message from configuration (#453)
1 parent 58d1401 commit f7fa54a

File tree

3 files changed

+15
-0
lines changed

3 files changed

+15
-0
lines changed

docs/configuration/overview.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ All `axion-release-plugin` configuration options:
3838
serialize({ tag, version -> ... }) // creates tag name from raw version
3939
deserialize( { tag, position, tagName -> ... }) // reads raw version from tag
4040
initialVersion({ tag, position -> ... }) // returns initial version if none found, 0.1.0 by default
41+
messageCreator({ position, version, previousVersion -> ... }) // returns tag message, empty String (default) means no message
4142
}
4243

4344
nextVersion { // doc: Next version markers

docs/configuration/version.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,19 @@ that will construct initial version:
197197

198198
Input objects have same structure as deserialization closure inputs.
199199

200+
### Tag message
201+
202+
The default message creator will skip adding a message by returning an empty string.
203+
204+
You can implement your own message creator by setting a closure that would accept
205+
position in SCM, current version and previous version:
206+
207+
scmVersion {
208+
tag {
209+
messageCreator({position, version, previousVersion -> ...})
210+
}
211+
}
212+
200213
## Incrementing
201214

202215
Incrementing phase does increment the version in accordance with

docs/examples/examples.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ scmVersion {
5656
// configure via function calls
5757
deserializer({ tagProperties, scmPosition, String -> "tag" })
5858
serializer({ tagProperties, version -> "tag" })
59+
messageCreator({ scmPosition, version, previousVersion -> "message" })
5960
}
6061
repository {
6162
type.set("git")

0 commit comments

Comments
 (0)