Merge pull request #51 from bootsie123/patch-1
Support for changing the default version bump
This commit is contained in:
commit
32df3182d2
|
@ -40,6 +40,14 @@ Make sure you use the `actions/checkout@v2` action!
|
||||||
skip-tag: 'true'
|
skip-tag: 'true'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
**default:** Set a default version bump to use (optional - defaults to patch). Example:
|
||||||
|
```yaml
|
||||||
|
- name: 'Automated Version Bump'
|
||||||
|
uses: 'phips28/gh-action-bump-version@master'
|
||||||
|
with:
|
||||||
|
default: prerelease
|
||||||
|
```
|
||||||
|
|
||||||
**wording:** Customize the messages that trigger the version bump. It must be a string, case sensitive, coma separated (optional). Example:
|
**wording:** Customize the messages that trigger the version bump. It must be a string, case sensitive, coma separated (optional). Example:
|
||||||
```yaml
|
```yaml
|
||||||
- name: 'Automated Version Bump'
|
- name: 'Automated Version Bump'
|
||||||
|
|
2
index.js
2
index.js
|
@ -31,7 +31,7 @@ Toolkit.run(async tools => {
|
||||||
const patchWords = process.env['INPUT_PATCH-WORDING'].split(',')
|
const patchWords = process.env['INPUT_PATCH-WORDING'].split(',')
|
||||||
const preReleaseWords = process.env['INPUT_RC-WORDING'].split(',')
|
const preReleaseWords = process.env['INPUT_RC-WORDING'].split(',')
|
||||||
|
|
||||||
let version = 'patch'
|
let version = process.env['DEFAULT'] || 'patch'
|
||||||
let foundWord = null;
|
let foundWord = null;
|
||||||
|
|
||||||
if (messages.some(
|
if (messages.some(
|
||||||
|
|
Loading…
Reference in New Issue