Skip to content

Commit 3926b43

Browse files
committed
feat(rule): skip merge commit
1 parent f525f5f commit 3926b43

5 files changed

Lines changed: 19 additions & 8 deletions

File tree

.github/workflows/goreleaser.yaml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
2-
1+
name: goreleaser
32

43
on:
54
push:
@@ -18,13 +17,12 @@ jobs:
1817
name: Set up Go
1918
uses: actions/setup-go@v2
2019
with:
21-
go-version: 1.15
20+
go-version: 1.17
2221
-
2322
name: Run GoReleaser
2423
uses: goreleaser/goreleaser-action@v2
2524
with:
2625
version: latest
2726
args: release --rm-dist
2827
env:
29-
# need to access other repository for brew-tap
30-
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
28+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.goreleaser.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
efore:
1+
before:
22
hooks:
33
- go mod tidy
44
builds:

action.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: 'Go commit linter'
2+
description: 'Inspect commit messages with the format "<type>(scope): <subject>".'
3+
inputs:
4+
message: # id of input
5+
description: 'commit message or pull request messaeg'
6+
required: true
7+
default: 'World'
8+
outputs:
9+
time: # id of output
10+
description: 'The time we greeted you'
11+
runs:
12+
using: 'node16'
13+
main: 'index.js'

main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ var (
5252

5353
DefaultConfig = Config{
5454
SkipPrefixes: []string{
55-
"Merge branch ",
55+
"Merge ",
5656
"BREAKING: ",
5757
},
5858
Reference: "https://github.com/masahiro331/go-commitlinter#description",

rule-sample.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22
skip_prefixes:
3-
- 'Merge branch '
3+
- 'Merge '
44
- 'BREAKING: '
55
type_rules:
66
- type: feat

0 commit comments

Comments
 (0)