From dbed65ffeb3bde22840709cdc73332794bbadc9d Mon Sep 17 00:00:00 2001 From: MDLeom <43627182+curbengh@users.noreply.github.com> Date: Sun, 1 Oct 2023 04:05:08 +0000 Subject: [PATCH] feat(ci): run linux jobs using Bun --- .github/workflows/linter.yml | 10 ++++------ .github/workflows/snyk.yml | 12 +++++------- .github/workflows/tester.yml | 4 +++- .gitignore | 1 + bunfig.toml | 5 +++++ 5 files changed, 18 insertions(+), 14 deletions(-) create mode 100644 bunfig.toml diff --git a/.github/workflows/linter.yml b/.github/workflows/linter.yml index ccc3c75..0289562 100644 --- a/.github/workflows/linter.yml +++ b/.github/workflows/linter.yml @@ -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 diff --git a/.github/workflows/snyk.yml b/.github/workflows/snyk.yml index 86bba8b..21420d9 100644 --- a/.github/workflows/snyk.yml +++ b/.github/workflows/snyk.yml @@ -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 diff --git a/.github/workflows/tester.yml b/.github/workflows/tester.yml index 3480e38..708e524 100644 --- a/.github/workflows/tester.yml +++ b/.github/workflows/tester.yml @@ -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: diff --git a/.gitignore b/.gitignore index a6d9d63..22bded3 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ package-lock.json tmp/ *.log coverage/ +bun.lockb diff --git a/bunfig.toml b/bunfig.toml new file mode 100644 index 0000000..0ede1d8 --- /dev/null +++ b/bunfig.toml @@ -0,0 +1,5 @@ +[install] +optional = false + +[install.lockfile] +save = false