We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e1a4f48 commit 3f0de15Copy full SHA for 3f0de15
1 file changed
.github/workflows/reusable-lint.yml
@@ -2,6 +2,10 @@ name: Reusable workflow example
2
3
on:
4
workflow_call:
5
+ inputs:
6
+ default-base-branch:
7
+ required: true
8
+ type: string
9
secrets:
10
NPM_TOKEN:
11
required: true
@@ -33,6 +37,6 @@ jobs:
33
37
34
38
- name: Run ESLint
35
39
run: |
36
- BASE_BRANCH=${GITHUB_BASE_REF:-master}
40
+ BASE_BRANCH=${GITHUB_BASE_REF:-${{ inputs.default-base-branch }}}
41
BASE_COMMIT=$(git merge-base HEAD origin/${BASE_BRANCH})
42
yarn lint-staged --concurrent=false --diff="${BASE_COMMIT}..HEAD" --verbose
0 commit comments