https://github.com/jenkinsci/maven-snapshot-check-plugin
https://plugins.jenkins.io/maven-snapshot-check
https://github.com/jenkinsci/maven-snapshot-check-plugin
jenkins-plugin maven-pom pom snapshot
Last synced: 3 months ago
JSON representation
https://plugins.jenkins.io/maven-snapshot-check
- Host: GitHub
- URL: https://github.com/jenkinsci/maven-snapshot-check-plugin
- Owner: jenkinsci
- License: mit
- Created: 2019-04-24T20:59:50.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2025-01-11T14:42:00.000Z (9 months ago)
- Last Synced: 2025-01-11T15:37:07.042Z (9 months ago)
- Topics: jenkins-plugin, maven-pom, pom, snapshot
- Language: Java
- Homepage: https://plugins.jenkins.io/maven-snapshot-check/
- Size: 267 KB
- Stars: 16
- Watchers: 3
- Forks: 12
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Maven SNAPSHOT Check Plugin
[](https://ci.jenkins.io/job/Plugins/job/maven-snapshot-check-plugin/job/master/)
[](https://codecov.io/gh/jenkinsci/maven-snapshot-check-plugin)
[](https://plugins.jenkins.io/maven-snapshot-check)
[](https://github.com/jenkinsci/maven-snapshot-check-plugin/releases/latest)
[](https://plugins.jenkins.io/maven-snapshot-check)[README δΈζη](README.zh.md)
This plugin used to check if pom.xml contains SNAPSHOT.
# Usage
## FreeStyle job usage
use the `Build Step` called `Maven SNAPSHOT Check` in `Build` section

If check the checkbox, it will check if pom.xml contains SNAPSHOT.

Then it will marked the build failed if matches.

## Maven job usage
use the `pre-build step` called `Maven SNAPSHOT Check` in `Pre Steps` section
## Pipeline job usage
```
step([$class: 'MavenSnapshotCheck', check: 'true'])
```
or
```
mavenSnapshotCheck check: 'true'
```
or, you can customize the pomFiles parameter to check only the specified pom files
(If the pomFiles parameter is not defined, its default value is `pom.xml, * */pom.xml`),
or, you can customize the excludePomFiles parameter to skip check the specified pom files
(If the excludePomFiles parameter is not defined, its default value is `null`),
```
mavenSnapshotCheck check: 'true', pomFiles: 'pom.xml,sub-dir/pom.xml', excludePomFiles: 'sub-dir-2/pom.xml'
```# Bug reports
Please report bugs and feature requests at https://github.com/jenkinsci/maven-snapshot-check-plugin/issues.# How to build and test
* Build the plugin:`mvn package`
* Test locally (invokes a local Jenkins instance with the plugin installed):
`mvn hpi:run`
See https://jenkinsci.github.io/maven-hpi-plugin/ for details.