You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In general pull requests and support for open issues is always welcome!
3
+
4
+
## Project layout
5
+
This project is a multi-module Maven project. It consists of the following modules:
6
+
-[core](core) (`git-commit-id-plugin-core`): The core framework of the plugin
7
+
-[maven](maven) (`git-commit-id-plugin`): The actual plugin, which depends on the `core` module
8
+
9
+
To build the project:
10
+
1. Install Maven
11
+
2. Install a JDK meeting the minimum requirements specified by Maven and in the [README](README.md)
12
+
3. Run the following command in the main directory of the project:
13
+
```
14
+
mvn clean verify
15
+
```
16
+
This will build the project and run all tests.
17
+
18
+
## Checkstyle
19
+
If you open a pull request or want to help out in any way please keep in mind that we currently use Checkstyle to ensure that the project somehow maintains a uniform code base. Fortunately the most common IDEs support the integration of Checkstyle via plugins. On top of more or less native integration into modern development tools the Checkstyle rules are currently also being verified by using the [maven-checkstyle-plugin](https://maven.apache.org/plugins/maven-checkstyle-plugin/) during the build. It should be worth to highlight that you are not required to install Checkstyle inside your IDE. If you feel more comfortable running the checks via Maven this would do the trick!
20
+
The Checkstyle rules for this project are currently residing in `.github/.checkstyle/` and for some IDEs those rules need to be imported manually (unfortunately there is no better solution available for this yet). The current rule set is pretty much the same as the `google_checks.xml` with certain checks disabled (e.g. line length). If you choose to integrate Checkstyle inside your IDE feel free to checkout some high level requirements to get started with Checkstyle within your IDE:
21
+
* Eclipse – for Eclipse / STS you would need to install the `Checkstyle Plug-in` via `Help -> Eclipse Marketplace -> Search` after restarting Eclipse it should pick-up the rules automatically.
22
+
* IntelliJ IDEA – for IntelliJ you would need to install the `CheckStyle-IDEA` plugin via `File -> Settings -> Plugins -> Search`. After restarting IntelliJ you would need to import the Checkstyle rules manually via `File -> Settings -> Checkstyle`. As Checkstyle version you may choose `8.2` and then click on the plus-sign on the right. As description you may choose `maven-git-commit-id-plugin` and as local Checkstyle file you may choose one of the Checkstyle rules residing in `.github/.checkstyle/`. Please note that the rule-file depends on the version you have selected in the previous step and thus it is essential to ensure that the version numbers match up. As next step you unfortunately will be prompted to enter the **full directory** of the `checkstyle-suppressions.xml`-file.
23
+
* NetBeans – feel free to open an issue and share your installation guide :-)
24
+
* Maven – if you want to run Checkstyle via Maven you simply can execute `mvn clean verify -Pcheckstyle -Dmaven.test.skip=true -B`.
Copy file name to clipboardExpand all lines: README.md
+17-14Lines changed: 17 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,13 +2,13 @@ maven git commit id plugin
2
2
==================================
3
3
4
4
[](https://gitter.im/git-commit-id/maven-git-commit-id-plugin?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
git-commit-id-plugin is a plugin quite similar to https://fisheye.codehaus.org/browse/mojo/tags/buildnumber-maven-plugin-1.0-beta-4 for example but as buildnumber at the time when I started this plugin only supported CVS and SVN, something had to be done.
11
-
I had to quickly develop an git version of such a plugin. For those who don't know the previous plugins, it basically helps you to help you with the following tasks and answer related questions
10
+
git-commit-id-plugin is a plugin quite similar to [Build Number Maven Plugin](https://www.mojohaus.org/buildnumber-maven-plugin/index.html) for example but as the Build Number plugin at the time when I started this plugin only supported CVS and SVN, something had to be done.
11
+
I had to quickly develop a Git version of such a plugin. For those who don't know the plugin, it basically helps you with the following tasks and answers related questions
12
12
* Which version had the bug? Is that deployed already?
13
13
* Make your distributed deployment aware of versions
The plugin **is available from Maven Central** (<ahref="http://search.maven.org/#search%7Cga%7C1%7Cpl.project13">see here</a>), so you don't have to configure any additional repositories to use this plugin.
29
+
The plugin **is available from Maven Central** ([see here](https://search.maven.org/artifact/pl.project13.maven/git-commit-id-plugin)), so you don't have to configure any additional repositories to use this plugin.
29
30
30
-
A detailed description of using the plugin is available in the [Using the plugin](maven/docs/using-the-plugin.md)section. All you need to do in the basic setup is to include that plugin definition in your `pom.xml`.
31
-
For more advanced users we also prepared a [guide to provide a brief overview of the more advanced configurations](maven/docs/using-the-plugin.md)<a>... read on!
31
+
A detailed description of using the plugin is available in the [Using the plugin](maven/docs/using-the-plugin.md)document. All you need to do in the basic setup is to include that plugin definition in your `pom.xml`.
32
+
For more advanced users we also prepared a [guide to provide a brief overview of the more advanced configurations](maven/docs/using-the-plugin.md)... read on!
32
33
33
34
Versions
34
35
--------
35
36
The current version is **4.0.0** ([changelist](https://github.com/git-commit-id/maven-git-commit-id-plugin/issues?q=milestone%3A4.0.0)).
36
37
37
-
You can check the available versions by visiting [search.maven.org](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22pl.project13.maven%22%20AND%20a%3A%22git-commit-id-plugin%22), though using the newest is obviously the best choice.
38
+
You can check the available versions by visiting [search.maven.org](https://search.maven.org/artifact/pl.project13.maven/git-commit-id-plugin), though using the newest is obviously the best choice.
38
39
39
40
Plugin compatibility with Java
40
41
-------------------------------
@@ -45,7 +46,7 @@ Plugin compatibility with Java
45
46
| 3.0.0 | Java 1.8 |
46
47
47
48
48
-
Plugin compatibility with maven
49
+
Plugin compatibility with Maven
49
50
-----------------------------
50
51
Even though this plugin tries to be compatible with every Maven version there are some known limitations with specific versions. Here is a list that tries to outline the current state of the art:
51
52
@@ -64,7 +65,7 @@ Starting with Maven 3.1.1 any plugin version is currently compatible. Only known
64
65
Getting SNAPSHOT versions of the plugin
65
66
---------------------------------------
66
67
If you really want to use **snapshots**, here's the repository they are deployed to.
67
-
But I highly recommend using only stable versions, from maven central... :-)
68
+
But I highly recommend using only stable versions, from Maven Central... :-)
68
69
69
70
```xml
70
71
<pluginRepositories>
@@ -101,9 +102,9 @@ I'd like to give a big thanks to some of these folks, for their suggestions and
101
102
Notable happy users
102
103
===================
103
104
104
-
*[neo4j](http://www.neo4j.org/) – graph database
105
-
*[foundationdb](http://foundationdb.com) – another open source database
106
-
*[Spring Boot](http://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#production-ready-git-commit-information) – yes, the upstream Spring project is using us
105
+
*[neo4j](https://neo4j.com/) – graph database
106
+
*[FoundationdDB](https://www.foundationdb.org/) – another open source database
107
+
*[Spring Boot](https://docs.spring.io/spring-boot/docs/current/reference/htmlsingle/#using-boot-maven) – yes, the upstream Spring project is using us
107
108
* Akamai, Sabre, EasyDITA, and many many others,
108
109
* many others I don't know of.
109
110
@@ -115,7 +116,9 @@ I'm releasing this plugin under the **GNU Lesser General Public License 3.0**.
115
116
116
117
You're free to use it as you wish, the full license text is attached in the LICENSE file.
117
118
118
-
The best way to ask for features / improvements is [via the Issues section on github - it's better than email](https://github.com/git-commit-id/maven-git-commit-id-plugin/issues) because I won't loose when I have a "million emails inbox" day,
119
+
Feature requests
120
+
================
121
+
The best way to ask for features / improvements is [via the Issues section on GitHub - it's better than email](https://github.com/git-commit-id/maven-git-commit-id-plugin/issues) because I won't loose when I have a "million emails inbox" day,
119
122
and maybe someone else has some idea or would like to upvote your issue.
Copy file name to clipboardExpand all lines: maven/docs/faq.md
+3-14Lines changed: 3 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,22 +29,11 @@ Example:
29
29
</plugin>
30
30
```
31
31
32
-
If you are using the maven build with [Maven's Plugin Prefix Resolution](https://maven.apache.org/guides/introduction/introduction-to-plugin-prefix-mapping.html) (e.g. `mvn somePrefix:goal`) please note that this currently seems to be [not supported by maven](https://issues.apache.org/jira/browse/MNG-6260).
33
-
Instead of using the Plugin Prefix Resolution add an execution tag that calls the desired goal of the plugin within a normal maven life cycle (e.g. `mvn clean package`).
32
+
If you are using the Maven build with [Maven's Plugin Prefix Resolution](https://maven.apache.org/guides/introduction/introduction-to-plugin-prefix-mapping.html) (e.g. `mvn somePrefix:goal`) please note that this currently seems to be [not supported by Maven](https://issues.apache.org/jira/browse/MNG-6260).
33
+
Instead of using the Plugin Prefix Resolution add an execution tag that calls the desired goal of the plugin within a normal Maven life cycle (e.g. `mvn clean package`).
34
34
35
35
Generated properties are not being used in install and/or deploy
36
36
-------------------------------
37
-
If you try to use generated properties like ${git.commit.id} alongside with your artificat finalName you will soon notice that those properties are not being used in install and/or deploy. This specific behaviour is basically not intended / not supported by maven-install-plugin and/or maven-deploy-plugin (https://issues.apache.org/jira/browse/MINSTALL-1 / https://issues.apache.org/jira/browse/MDEPLOY-93). The naming format in the remote repo seems always $artifactId-$version-$classifier *by default* and thus any generated property will not end up inside the artifact being installed/deployed. If you for whatever reason still want to have something special you may want to [checkout a full workaround](https://github.com/git-commit-id/maven-git-commit-id-plugin/issues/256#issuecomment-321476196) that uses a specific configuration of `install-file` / `deploy-file`.
37
+
If you try to use generated properties like `${git.commit.id}` alongside with your artifact finalName you will soon notice that those properties are not being used in install and/or deploy. This specific behaviour is basically not intended / not supported by maven-install-plugin and/or maven-deploy-plugin (https://issues.apache.org/jira/browse/MINSTALL-1 / https://issues.apache.org/jira/browse/MDEPLOY-93). The naming format in the remote repo seems to be always `$artifactId-$version-$classifier`*by default* and thus any generated property will not end up inside the artifact being installed/deployed. If you for whatever reason still want to have something special you may want to [checkout a full workaround](https://github.com/git-commit-id/maven-git-commit-id-plugin/issues/256#issuecomment-321476196) that uses a specific configuration of `install-file` / `deploy-file`.
38
38
39
39
As a general note also ensure to use `mvn clean deploy` instead of `mvn deploy:deploy` (or you run into https://issues.apache.org/jira/browse/MNG-6260) and ensure to set `<injectAllReactorProjects>true</injectAllReactorProjects>` inside the plugin's config.
40
-
41
-
How to contribute to the project
42
-
-------------------------------
43
-
In general pull requests and support for open issues is always welcome!
44
-
If you open a pull request or want to help out in any way please keep in mind that we currently use `checkstyle` to ensure that the project somehow maintains a uniform code base. Fortunately the most common IDEs support the integration of `checkstyle` via plugins. On top of more or less native integration into modern development tools the `checkstyle` rules are currently also being verified by using the [maven-checkstyle-plugin](https://maven.apache.org/plugins/maven-checkstyle-plugin/) during the build. it should be worth to highlight that you are not required to install `checkstyle` inside your IDE. If you feel more comfortable running the checks via maven this would to the trick!
45
-
The checkstyle rules for this project are currently residing in `src/test/resources/checks` and for some IDEs those rules need to be imported manually (unfortunately there is no better solution available for this yet). The current rule set is pretty much the same as the `google_checks.xml` with certain checks disabled (e.g. line length). If you choose to integrate `checkstyle` inside your IDE feel free to checkout some high level requirements to get started with checkstyle within your IDE:
46
-
* eclipse -- for eclipse / STS you would need to install the `checkstyle plug-in` via `Help -> Eclipse Marketplace -> Search` after restarting eclipse it should pick-up the rules automatically. If this does not work out of the box checkout the [official integration guide](http://checkstyle.sourceforge.net/eclipse.html) or use google to trace down your error message.
47
-
* IntelliJ IDEA -- for IntelliJ you would need to install the `CheckStyle-IDEA` via `File -> Settings -> Plugins -> Search`. After restarting IntelliJ you would need to import the `checkstyle` rules manually via `File -> Settings -> Checkstyle`. As checkstyle version you may choose `8.2` and then click on the plus-sign on the right. As description you may choose `maven-git-commit-id-plugin` and as local checkstyle file you may choose one of the checkstyle rule residing in `src/test/resources/checks`. Please note that the rule-file depend on the version you have selected in the previous step and thus it is essential to ensure that the version numbers match up. As next-step you unfortunately will be prompted to enter the **full directory** of the `checkstyle-suppressions.xml`-File. If this does not work out of the box checkout the [official integration guide](http://checkstyle.sourceforge.net/idea.html) or use google to trace down your error message.
48
-
* Netbeans -- feel free to open a ticket and share your installation guide :-) You can also check out the [official integration guide](http://checkstyle.sourceforge.net/netbeans.html) or use google to get any addtional help.
49
-
* Maven -- if you want to run `checkstyle` via maven you simply can execute `mvn clean verify -Pcheckstyle -Dmaven.test.skip=true -B`.
0 commit comments