-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
31 lines (31 loc) · 1.13 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
name: 'Node.js Project Semantic Version Check'
description: 'Check Node.js project semantic version'
author: 'wmdanor'
inputs:
token:
description: 'GutHub Token'
required: true
package-json-path:
description: 'Path to package.json file'
required: true
default: 'package.json'
main-branch-name:
description: 'Main branch name'
required: true
default: 'main'
outputs:
thisBranchInitialVersion:
description: 'This branch initial version (it is Version object { value, major, minor, patch, build, prerelease } ). Use like: steps.checkVersion.outputs["thisBranchInitialVersion.value"]'
thisBranchCurrentVersion:
description: 'This branch current version (it is Version object)'
mainBranchCurrentVersion:
description: 'Main branch current version (it is Version object)'
hasChanged:
description: 'True if (thisBranchCurrentVersion !== thisBranchInitialVersion)'
isValid:
description: 'Valid if (thisBranchCurrentVersion > thisBranchInitialVersion && thisBranchCurrentVersion > mainBranchCurrentVersion)'
errors:
description: 'Validation errors'
runs:
using: 'node16'
main: 'dist/index.js'