Skip to content

Commit 4345a9a

Browse files
chainchadldez
authored andcommitted
Add built dist files
1 parent d65c876 commit 4345a9a

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

dist/post_run/index.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66574,15 +66574,17 @@ function runLint(lintPath, patchPath) {
6657466574
printOutput(res);
6657566575
}
6657666576
const userArgs = core.getInput(`args`);
66577+
const allowExtraOutFormatArgs = core.getInput(`allow-extra-out-format-args`);
6657766578
const addedArgs = [];
6657866579
const userArgNames = new Set(userArgs
6657966580
.trim()
6658066581
.split(/\s+/)
6658166582
.map((arg) => arg.split(`=`)[0])
6658266583
.filter((arg) => arg.startsWith(`-`))
6658366584
.map((arg) => arg.replace(/^-+/, ``)));
66584-
if (userArgNames.has(`out-format`)) {
66585-
throw new Error(`please, don't change out-format for golangci-lint: it can be broken in a future`);
66585+
if (userArgNames.has(`out-format`) && !allowExtraOutFormatArgs) {
66586+
throw new Error(`please, don't change out-format for golangci-lint: it can be broken in a
66587+
future version (set 'allow-extra-out-format-args' input to true to override)`);
6658666588
}
6658766589
addedArgs.push(`--out-format=github-actions`);
6658866590
if (patchPath) {

dist/run/index.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66574,15 +66574,17 @@ function runLint(lintPath, patchPath) {
6657466574
printOutput(res);
6657566575
}
6657666576
const userArgs = core.getInput(`args`);
66577+
const allowExtraOutFormatArgs = core.getInput(`allow-extra-out-format-args`);
6657766578
const addedArgs = [];
6657866579
const userArgNames = new Set(userArgs
6657966580
.trim()
6658066581
.split(/\s+/)
6658166582
.map((arg) => arg.split(`=`)[0])
6658266583
.filter((arg) => arg.startsWith(`-`))
6658366584
.map((arg) => arg.replace(/^-+/, ``)));
66584-
if (userArgNames.has(`out-format`)) {
66585-
throw new Error(`please, don't change out-format for golangci-lint: it can be broken in a future`);
66585+
if (userArgNames.has(`out-format`) && !allowExtraOutFormatArgs) {
66586+
throw new Error(`please, don't change out-format for golangci-lint: it can be broken in a
66587+
future version (set 'allow-extra-out-format-args' input to true to override)`);
6658666588
}
6658766589
addedArgs.push(`--out-format=github-actions`);
6658866590
if (patchPath) {

0 commit comments

Comments
 (0)