From 57d0bc3e8d53a2f84aa7fdb105ffc5d7721221ba Mon Sep 17 00:00:00 2001 From: Doug Richar Date: Thu, 5 Oct 2023 19:02:53 -0400 Subject: [PATCH] ci: update actions to use node 18, include linting checks in CI --- .github/workflows/ci.yml | 8 +++++++- .github/workflows/release.yml | 16 ++++++++++++++-- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 98f785bb..26d4bd38 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,11 +22,17 @@ jobs: - name: Set up Node uses: actions/setup-node@v3 with: - node-version: 16 + node-version: 18 - name: Install dependencies (with cache) uses: bahmutov/npm-install@v1 + - name: Run ESLint + run: yarn lint + + - name: Run Prettier check + run: yarn prettier + - name: Run TypeScript type check run: yarn check-types diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fbb64201..a57e0a06 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,23 +1,35 @@ name: Release & Publish to NPM + on: workflow_dispatch + jobs: release: runs-on: ubuntu-latest + steps: - - name: Checkout source code - uses: actions/checkout@v2 + - name: Checkout repository + uses: actions/checkout@v3 with: fetch-depth: 0 + + - name: Set up Node + uses: actions/setup-node@v3 + with: + node-version: 18 + - name: Install dependencies run: yarn install --frozen-lockfile + - name: Initialize Git user run: | git config --global user.email "drichar@gmail.com" git config --global user.name "GitHub Actions" + - name: Initialize NPM config run: npm config set //registry.npmjs.org/:_authToken $NPM_TOKEN env: NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + - name: Run release run: yarn release --ci env: