[CI] Re-arrange create-cache.yml (#20829)

This commit is contained in:
Mac Siri 2024-04-02 18:26:03 -04:00 committed by GitHub
parent 23b9516d5b
commit e22e6284e4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -14,12 +14,7 @@ jobs:
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
cache: yarn
- run: yarn install --immutable
- name: cache compiled assets exist
- name: Cache compiled assets
uses: actions/cache@v4
with:
fail-on-cache-miss: false
@ -27,4 +22,9 @@ jobs:
public/assets
key: ${{ runner.os }}-compiled-assets-v3-${{ hashFiles('app/assets/(fonts|images|javascripts|stylesheets)/**', 'app/javascript/**', '**/package.json', '**/yarn.lock') }}
restore-keys: ${{ runner.os }}-compiled-assets-v3-
- uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
cache: yarn
- run: yarn install --immutable
- run: bundle exec rails assets:precompile