17
17
node-version : ' 12.16.2'
18
18
- name : Install Yarn
19
19
run : curl -o- -L https://yarnpkg.com/install.sh | bash
20
+ - name : Get yarn cache directory path
21
+ id : yarn-cache-dir-path
22
+ run : echo "::set-output name=dir::$(yarn cache dir)"
23
+ - name : Cache dependencies
24
+ uses : actions/cache@v1
25
+ id : yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
26
+ with :
27
+ path : ${{ steps.yarn-cache-dir-path.outputs.dir }}
28
+ key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
29
+ restore-keys : |
30
+ ${{ runner.os }}-yarn-
20
31
- name : Install dependencies with Yarn
21
32
run : yarn install
22
33
- name : Compile TypeScript
40
51
node-version : ' 12.16.2'
41
52
- name : Install Yarn
42
53
run : curl -o- -L https://yarnpkg.com/install.sh | bash
54
+ - name : Get yarn cache directory path
55
+ id : yarn-cache-dir-path
56
+ run : echo "::set-output name=dir::$(yarn cache dir)"
57
+ - name : Cache dependencies
58
+ uses : actions/cache@v1
59
+ id : yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
60
+ with :
61
+ path : ${{ steps.yarn-cache-dir-path.outputs.dir }}
62
+ key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
63
+ restore-keys : |
64
+ ${{ runner.os }}-yarn-
43
65
- name : Install dependencies with Yarn
44
66
run : yarn install
45
67
- name : Lint with XO
58
80
node-version : ' 12.16.2'
59
81
- name : Install Yarn
60
82
run : curl -o- -L https://yarnpkg.com/install.sh | bash
83
+ - name : Get yarn cache directory path
84
+ id : yarn-cache-dir-path
85
+ run : echo "::set-output name=dir::$(yarn cache dir)"
86
+ - name : Cache dependencies
87
+ uses : actions/cache@v1
88
+ id : yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
89
+ with :
90
+ path : ${{ steps.yarn-cache-dir-path.outputs.dir }}
91
+ key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
92
+ restore-keys : |
93
+ ${{ runner.os }}-yarn-
61
94
- name : Install dependencies with Yarn
62
95
run : yarn install
63
96
- name : Check style with Prettier
@@ -78,6 +111,17 @@ jobs:
78
111
node-version : ' 12.16.2'
79
112
- name : Install Yarn
80
113
run : curl -o- -L https://yarnpkg.com/install.sh | bash
114
+ - name : Get yarn cache directory path
115
+ id : yarn-cache-dir-path
116
+ run : echo "::set-output name=dir::$(yarn cache dir)"
117
+ - name : Cache dependencies
118
+ uses : actions/cache@v1
119
+ id : yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
120
+ with :
121
+ path : ${{ steps.yarn-cache-dir-path.outputs.dir }}
122
+ key : ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
123
+ restore-keys : |
124
+ ${{ runner.os }}-yarn-
81
125
- name : Install dependencies with Yarn
82
126
run : yarn install
83
127
- name : Compile TypeScript for publishing
0 commit comments