From e4f1b1f77d86bbe3761a84fa52dd933ae0330b74 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20O=E2=80=99Connor?= Date: Wed, 17 Jun 2020 08:44:12 -0700 Subject: [PATCH] Cache `yarn install` in GitHub Actions (#692) --- .github/workflows/test.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2352b0629..c624d76ef 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,6 +12,13 @@ jobs: uses: actions/setup-node@v1 with: node-version: 12.x + - name: Restore Yarn cache + uses: actions/cache@v2 + with: + path: | + node_modules + */*/node_modules + key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }} - name: Install dependencies run: | yarn install --frozen-lockfile @@ -27,6 +34,13 @@ jobs: uses: actions/setup-node@v1 with: node-version: 12.x + - name: Restore Yarn cache + uses: actions/cache@v2 + with: + path: | + node_modules + */*/node_modules + key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }} - name: Install dependencies run: | yarn install --frozen-lockfile @@ -42,6 +56,13 @@ jobs: uses: actions/setup-node@v1 with: node-version: 12.x + - name: Restore Yarn cache + uses: actions/cache@v2 + with: + path: | + node_modules + */*/node_modules + key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }} - name: Install dependencies run: | yarn install --frozen-lockfile @@ -57,6 +78,13 @@ jobs: uses: actions/setup-node@v1 with: node-version: 12.x + - name: Restore Yarn cache + uses: actions/cache@v2 + with: + path: | + node_modules + */*/node_modules + key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }} - name: Install dependencies run: | yarn install --frozen-lockfile @@ -72,6 +100,13 @@ jobs: uses: actions/setup-node@v1 with: node-version: 12.x + - name: Restore Yarn cache + uses: actions/cache@v2 + with: + path: | + node_modules + */*/node_modules + key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }} - name: Install dependencies run: | yarn install --frozen-lockfile