From aed810cb83a42069ae1624f4158cf07b7bc8fa4d Mon Sep 17 00:00:00 2001 From: Fred Cooke Date: Sun, 13 Jan 2013 11:58:52 +0100 Subject: [PATCH 1/2] Include a mention of the default phase, initialize, with US spelling, in the docs. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 100d3365..08b321c1 100644 --- a/README.md +++ b/README.md @@ -56,7 +56,7 @@ But I highly recommend using only stable versions, from maven central... :-) Using the plugin ---------------- -It's really simple to setup this plugin, here's a sample pom that you may base your **pom.xml** on: +It's really simple to setup this plugin; below is a sample pom that you may base your **pom.xml** on. Note that it binds to the initialize phase by default such that all Git properties are available for use throughout the build lifecycle. ```xml From d544ccfed81656e66801d316e6d2c27dba585ed0 Mon Sep 17 00:00:00 2001 From: Fred Cooke Date: Sun, 13 Jan 2013 12:08:14 +0100 Subject: [PATCH 2/2] Add a new section describing how to do it without spring or properties lookups. --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 08b321c1..441d17c9 100644 --- a/README.md +++ b/README.md @@ -382,6 +382,11 @@ public GitRepositoryState(Properties properties) } ``` +Yet another way to use the plugin +================================= + +Rather than reading properties files at runtime or injecting with spring, you can filter a Java source file directly and place it into src/main/java with an ignore, or into generated sources directory within the target directory. This has some minor advantages and disadvantages, but is useful for avoiding runtime injection or lookup from properties files that might get lost during repackaging later if used within a library. + Git describe - short intro to an awesome command ================================================== Git's [describe command](http://www.kernel.org/pub/software/scm/git/docs/git-describe.html) is the best way to really see "where" a commit is in the repositories "timeline".