mirror of
https://gitea.com/actions/setup-deno.git
synced 2025-12-13 11:56:58 +00:00
feat: add built-in caching via inputs (#89)
This commit is contained in:
committed by
GitHub
parent
a1496dd8d9
commit
fd6b0ad149
35
.github/workflows/test.yml
vendored
35
.github/workflows/test.yml
vendored
@@ -80,6 +80,41 @@ jobs:
|
||||
- name: Check binary exists
|
||||
run: deno_foo -V
|
||||
|
||||
test-setup-cache:
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Deno
|
||||
uses: ./
|
||||
with:
|
||||
cache: true
|
||||
cache-hash: ${{ hashFiles('**/deno.lock') }}
|
||||
|
||||
- name: Download dependencies for cache
|
||||
run: deno install --global --no-config npm:cowsay@1.6.0
|
||||
|
||||
test-cache:
|
||||
needs: test-setup-cache
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Deno
|
||||
uses: ./
|
||||
with:
|
||||
cache: true
|
||||
cache-hash: ${{ hashFiles('**/deno.lock') }}
|
||||
|
||||
- name: Run with cached dependencies
|
||||
run: deno run --cached-only --no-config -RE npm:cowsay@1.6.0 "It works!"
|
||||
|
||||
lint:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
Reference in New Issue
Block a user