feat(ci): run linux jobs using Bun

This commit is contained in:
MDLeom 2023-10-01 04:05:08 +00:00
parent c964cfcf80
commit dbed65ffeb
No known key found for this signature in database
GPG Key ID: 06C236E63CBC68AA
5 changed files with 18 additions and 14 deletions

View File

@ -7,10 +7,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: "16.x"
- name: Install Bun
uses: oven-sh/setup-bun@v1
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
@ -19,6 +17,6 @@ jobs:
restore-keys: |
${{ runner.os }}-npm-cache
- name: Install Dependencies
run: npm install
run: bun install
- name: Lint
run: npm run lint
run: bun run lint

View File

@ -3,22 +3,20 @@ name: Snyk
on:
schedule:
# Weekly
- cron: '0 0 * * 0'
- cron: "0 0 * * 0"
pull_request:
branches:
- 'dependabot/github_actions/github/codeql-action**'
- "dependabot/github_actions/github/codeql-action**"
jobs:
security:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 16.x
uses: actions/setup-node@v3
with:
node-version: '16.x'
- name: Install Bun
uses: oven-sh/setup-bun@v1
- name: Install Dependencies
run: npm install
run: bun install
- name: Run Snyk to check for vulnerabilities
uses: snyk/actions/node@master
continue-on-error: true # To make sure that SARIF upload gets called

View File

@ -40,6 +40,8 @@ jobs:
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Install Bun
uses: oven-sh/setup-bun@v1
- name: Cache NPM dependencies
uses: actions/cache@v3
with:
@ -47,7 +49,7 @@ jobs:
key: ${{ runner.os }}-npm-cache
restore-keys: ${{ runner.os }}-npm-cache
- name: Install Dependencies
run: npm install
run: bun install
- name: Coverage
run: npm run test
env:

1
.gitignore vendored
View File

@ -4,3 +4,4 @@ package-lock.json
tmp/
*.log
coverage/
bun.lockb

5
bunfig.toml Normal file
View File

@ -0,0 +1,5 @@
[install]
optional = false
[install.lockfile]
save = false