1717 with :
1818 fetch-depth : 3
1919 - uses : technote-space/get-diff-action@gh-actions
20- id : git-diff
2120 with :
2221 PREFIX_FILTER : |
2322 src/
@@ -27,21 +26,21 @@ jobs:
2726 - name : Get Yarn Cache Directory
2827 id : yarn-cache
2928 run : echo "::set-output name=dir::$(yarn cache dir)"
30- if : steps.git-diff.outputs.diff
29+ if : env.GIT_DIFF
3130 - name : Cache node dependencies
3231 uses : actions/cache@v1
3332 with :
3433 path : ${{ steps.yarn-cache.outputs.dir }}
3534 key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
3635 restore-keys : |
3736 ${{ runner.os }}-yarn-
38- if : steps.git-diff.outputs.diff
37+ if : env.GIT_DIFF
3938 - name : Install Package dependencies
4039 run : yarn install
41- if : steps.git-diff.outputs.diff
40+ if : env.GIT_DIFF
4241 - name : Check code style
43- run : yarn eslint ${{ steps.git-diff.outputs.diff }}
44- if : steps.git-diff.outputs.diff
42+ run : yarn eslint ${{ env.GIT_DIFF }}
43+ if : env.GIT_DIFF
4544 - uses : 8398a7/action-slack@v1
4645 with :
4746 type : failure
6261 with :
6362 fetch-depth : 3
6463 - uses : technote-space/get-diff-action@gh-actions
65- id : git-diff
6664 with :
6765 PREFIX_FILTER : |
6866 src/
@@ -75,31 +73,31 @@ jobs:
7573 uses : actions/setup-node@v1
7674 with :
7775 node-version : ${{ matrix.node }}
78- if : steps.git-diff.outputs.diff || github.event_name == 'push'
76+ if : env.GIT_DIFF || github.event_name == 'push'
7977 - name : Get Yarn Cache Directory
8078 id : yarn-cache
8179 run : echo "::set-output name=dir::$(yarn cache dir)"
82- if : steps.git-diff.outputs.diff || github.event_name == 'push'
80+ if : env.GIT_DIFF || github.event_name == 'push'
8381 - name : Cache node dependencies
8482 uses : actions/cache@v1
8583 with :
8684 path : ${{ steps.yarn-cache.outputs.dir }}
8785 key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
8886 restore-keys : |
8987 ${{ runner.os }}-yarn-
90- if : steps.git-diff.outputs.diff || github.event_name == 'push'
88+ if : env.GIT_DIFF || github.event_name == 'push'
9189 - name : Install Package dependencies
9290 run : yarn install
93- if : steps.git-diff.outputs.diff || github.event_name == 'push'
91+ if : env.GIT_DIFF || github.event_name == 'push'
9492 - name : Run tests
9593 run : yarn cover
96- if : steps.git-diff.outputs.diff || github.event_name == 'push'
94+ if : env.GIT_DIFF || github.event_name == 'push'
9795 - name : Codecov
9896 run : curl -s https://codecov.io/bash | bash -s -- -t $CODECOV_TOKEN -f $COVERAGE_FILE
9997 env :
10098 CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
10199 COVERAGE_FILE : ./coverage/lcov.info
102- if : matrix.node == '12' && (steps.git-diff.outputs.diff || github.event_name == 'push')
100+ if : matrix.node == '12' && (env.GIT_DIFF || github.event_name == 'push')
103101 - uses : 8398a7/action-slack@v1
104102 with :
105103 type : failure
0 commit comments