From dc61f27b214bd49eb9e6182d4cbff7b1facc6cd2 Mon Sep 17 00:00:00 2001 From: marv Date: Thu, 8 Aug 2024 22:23:07 -0700 Subject: [PATCH] Add Workflow for `prettier --check .` --- .github/workflows/prettier-check.yml | 15 +++++++++++++++ package.json | 1 + 2 files changed, 16 insertions(+) create mode 100644 .github/workflows/prettier-check.yml diff --git a/.github/workflows/prettier-check.yml b/.github/workflows/prettier-check.yml new file mode 100644 index 0000000..fbb3d30 --- /dev/null +++ b/.github/workflows/prettier-check.yml @@ -0,0 +1,15 @@ +name: Prettier Check + +on: [push, pull_request] + +jobs: + prettier-check: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 20 + - run: npm ci + - run: npm run check-format diff --git a/package.json b/package.json index 5d0af74..f627bd5 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "main": "dist/index.js", "scripts": { "format": "npx prettier --write .", + "check-format": "npx prettier --check .", "build": "tsc", "prepublish": "npm run build" },