File tree Expand file tree Collapse file tree 5 files changed +11
-4
lines changed Expand file tree Collapse file tree 5 files changed +11
-4
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"problemMatcher" : [
3
3
{
4
- "owner" : " golangci-lint-action " ,
4
+ "owner" : " go " ,
5
5
"pattern" : [
6
6
{
7
7
"regexp" : " ^\\ s*(\\ .{0,2}[\\ /\\\\ ].+\\ .go):(?:(\\ d+):(\\ d+):)? (.*)" ,
Original file line number Diff line number Diff line change @@ -5721,7 +5721,7 @@ function runLint(lintPath) {
5721
5721
if (args.includes(`-out-format`)) {
5722
5722
throw new Error(`please, don't change out-format for golangci-lint: it can be broken in a future`);
5723
5723
}
5724
- const cmd = `${lintPath} run ${args}`.trimRight();
5724
+ const cmd = `${lintPath} run --out-format=github-actions ${args}`.trimRight();
5725
5725
core.info(`Running [${cmd}] ...`);
5726
5726
const startedAt = Date.now();
5727
5727
try {
Original file line number Diff line number Diff line change @@ -5733,7 +5733,7 @@ function runLint(lintPath) {
5733
5733
if (args.includes(`-out-format`)) {
5734
5734
throw new Error(`please, don't change out-format for golangci-lint: it can be broken in a future`);
5735
5735
}
5736
- const cmd = `${lintPath} run ${args}`.trimRight();
5736
+ const cmd = `${lintPath} run --out-format=github-actions ${args}`.trimRight();
5737
5737
core.info(`Running [${cmd}] ...`);
5738
5738
const startedAt = Date.now();
5739
5739
try {
Original file line number Diff line number Diff line change @@ -4,11 +4,18 @@ package sample
4
4
import (
5
5
"crypto/md5"
6
6
"encoding/hex"
7
+ "errors"
7
8
)
8
9
9
10
// Hash~
10
11
func Hash (data string ) string {
12
+ retError ()
13
+
11
14
h := md5 .New ()
12
15
h .Write ([]byte (data ))
13
16
return hex .EncodeToString (h .Sum (nil ))
14
17
}
18
+
19
+ func retError () error {
20
+ return errors .New ("err" )
21
+ }
Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ async function runLint(lintPath: string): Promise<void> {
55
55
throw new Error ( `please, don't change out-format for golangci-lint: it can be broken in a future` )
56
56
}
57
57
58
- const cmd = `${ lintPath } run ${ args } ` . trimRight ( )
58
+ const cmd = `${ lintPath } run --out-format=github-actions ${ args } ` . trimRight ( )
59
59
core . info ( `Running [${ cmd } ] ...` )
60
60
const startedAt = Date . now ( )
61
61
try {
You can’t perform that action at this time.
0 commit comments