Skip to content

Commit

Permalink
feat(#7): update README file
Browse files Browse the repository at this point in the history
  • Loading branch information
volodya-lombrozo committed Oct 28, 2021
1 parent bb7ab44 commit 6946347
Showing 1 changed file with 44 additions and 10 deletions.
54 changes: 44 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,14 @@ Maven Plugin linter for [conventional commits](https://www.conventionalcommits.o

# How to use

Add plugin to pom.xml (to plugins section)
Add the plugin to your `pom.xml` file to the plugins section.

```XML

<plugin>
<groupId>com.github.volodya-lombrozo</groupId>
<artifactId>conventional-commit-linter</artifactId>
<version>0.0.5</version>
<configuration>
<scan>ALL</scan>
</configuration>
<version>0.0.6</version>
<executions>
<execution>
<goals>
Expand All @@ -27,12 +25,48 @@ Add plugin to pom.xml (to plugins section)
</executions>
</plugin>
```

The default maven phase is **validate**.

## Change scan mode

Available scan modes:

* ALL - the plugin will scan all repository commits messages one by one starting from the earliest. Conventional commits
format will be used.
* LAST - the plugin will scan only the last commit. Conventional commits format will be used.
* NOTHING - the plugin will scan nothing. Validation will always be **successful** regardless of the commit messages.
* FAIL - the plugin will scan nothing. Validation will always be **failed** regardless of the commit messages.
* **ALL** - the plugin will scan all repository commits messages one by one starting from the earliest. Conventional
commits format will be used.
* **LAST** - the plugin will scan only the last commit. Conventional commits format will be used.
* **NOTHING** - the plugin will scan nothing. Validation will always be **successful** regardless of the commit
messages.
* **FAIL** - the plugin will scan nothing. Validation will always be **failed** regardless of the commit messages.

The default plugin mode is the **LAST**.
In order to change a scan mode you could add the next configuration to your plugin:

```xml

<configuration>
<scan>ALL</scan>
</configuration>
```

The full plugin example:

```xml
<plugin>
<groupId>com.github.volodya-lombrozo</groupId>
<artifactId>conventional-commit-linter</artifactId>
<version>0.0.6</version>
<configuration>
<scan>FAIL</scan>
</configuration>
<executions>
<execution>
<goals>
<goal>
scan
</goal>
</goals>
</execution>
</executions>
</plugin>
```

0 comments on commit 6946347

Please sign in to comment.