From 0bc089ed46bbebb0731801a6bb2aca1cb63de975 Mon Sep 17 00:00:00 2001 From: Quoc Huynh Date: Tue, 21 Nov 2023 11:32:04 +0100 Subject: [PATCH] Cache asdf in workflow --- .github/workflows/main.yaml | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 1bc9a1b..9baed7e 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -7,15 +7,21 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + + - name: Cache asdf + uses: actions/cache@v3 + id: asdf_cache + with: + path: ~/.asdf/ + key: ${{ runner.os }}-${{ hashFiles('**/.tool-versions') }} - uses: asdf-vm/actions/install@v3 - - name: Cache dependencies + - name: Cache flutter dependencies uses: actions/cache@v3 - id: cache + id: flutter_cache with: - path: | - .dart_tool/ - key: ${{ runner.os }}-dependencies-${{ hashFiles('**/pubspec.lock') }} + path: .dart_tool/ + key: ${{ runner.os }}-${{ hashFiles('**/pubspec.lock') }} - name: Install Dependencies run: | flutter pub get