mirror of
https://github.com/oven-sh/setup-bun.git
synced 2025-07-17 20:18:24 +02:00
Various improvements and fixes to setup-bun (#40)
* Do not save cache on hit * Support Windows (canary only) * Support `registry-url` and `scope`
This commit is contained in:
parent
830e319e28
commit
a93230df19
14 changed files with 994 additions and 78881 deletions
65
.github/workflows/test.yml
vendored
Normal file
65
.github/workflows/test.yml
vendored
Normal file
|
@ -0,0 +1,65 @@
|
|||
name: Test
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
setup-bun:
|
||||
runs-on: ${{ matrix.os }}
|
||||
continue-on-error: true
|
||||
strategy:
|
||||
matrix:
|
||||
include:
|
||||
- os: windows-latest
|
||||
bun-version: canary
|
||||
os:
|
||||
- ubuntu-latest
|
||||
- macos-latest
|
||||
bun-version:
|
||||
- latest
|
||||
- canary
|
||||
- "0.8.1" # last version before 1.0
|
||||
- "0.x"
|
||||
- "1.0.0"
|
||||
- "1.x"
|
||||
- "1"
|
||||
- "> 1.0.0"
|
||||
- "< 2"
|
||||
# Disable <sha> support for now. This is because Github Artifacts
|
||||
# expire after 90 days, and we don't have another source of truth yet.
|
||||
# - "822a00c4d508b54f650933a73ca5f4a3af9a7983" # 1.0.0 commit
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Setup Bun
|
||||
uses: ./
|
||||
with:
|
||||
bun-version: ${{ matrix.bun-version }}
|
||||
- name: Run Bun
|
||||
run: |
|
||||
bun --version
|
||||
setup-bun-from-package-json-version:
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os:
|
||||
- ubuntu-latest
|
||||
- macos-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
- name: Setup package.json
|
||||
run: |
|
||||
echo "$(jq '. += {"packageManager": "bun@1.0.0"}' package.json)" > package.json
|
||||
- name: Setup Bun
|
||||
uses: ./
|
||||
- name: Run Bun
|
||||
run: |
|
||||
bun --version
|
Loading…
Add table
Add a link
Reference in a new issue