Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 11 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ jobs:
test:
name: Node ${{ matrix.node }} and ${{ matrix.os }}
timeout-minutes: 30
env:
COREPACK_DEFAULT_TO_LATEST: '0'
COREPACK_ENABLE_STRICT: '0'
strategy:
fail-fast: false
matrix:
Expand All @@ -28,12 +31,12 @@ jobs:
pull-requests: write # to be able to comment on released pull requests
id-token: write # required for npm trusted publishing (OIDC)
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
# https://github.com/nodejs/node-gyp#installation
- name: Use Python 3.11
- name: Use Python 3.12
uses: actions/setup-python@v6
with:
python-version: '3.11'
python-version: '3.12'
# https://github.com/hargasinski/node-canvas/blob/e7abe64833d13ec96449c827b1e14befbdf3105d/.github/workflows/ci.yaml#L70
- name: "macOS dependencies"
if: matrix.os == 'macos-latest'
Expand All @@ -46,28 +49,27 @@ jobs:
run: |
sudo apt update
sudo apt install -y libcairo2-dev libjpeg-dev libpango1.0-dev libgif-dev librsvg2-dev
- uses: pnpm/action-setup@v4
with:
run_install: false
- name: Enable Corepack
run: corepack enable pnpm
- name: Use Node.js ${{ matrix.node }}
uses: actions/setup-node@v6
with:
cache: pnpm
node-version: ${{ matrix.node }}
check-latest: true
- name: Install Dependencies
run: pnpm add --global node-gyp && pnpm install --frozen-lockfile
run: npm i -g node-gyp && pnpm install --frozen-lockfile
- name: Build Test Binary
run: pnpm build-test-binary
- name: Build
run: pnpm build
- name: Run Tests
run: pnpm test
- name: Coverage
if: matrix.os == 'ubuntu-latest' && matrix.node == 22 # only run once
if: matrix.os == 'ubuntu-latest' && matrix.node == 24 # only run once
run: pnpm test-coverage
- name: Maybe Release
if: matrix.os == 'ubuntu-latest' && matrix.node == 22 && github.event_name == 'push' && github.ref == 'refs/heads/main'
if: matrix.os == 'ubuntu-latest' && matrix.node == 24 && github.event_name == 'push' && github.ref == 'refs/heads/main'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: pnpm --dir publish install --ignore-workspace --frozen-lockfile && ./publish/node_modules/.bin/semantic-release
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"license": "MIT",
"main": "./dist/ncc/index.js",
"bin": {
"ncc": "./dist/ncc/cli.js"
"ncc": "dist/ncc/cli.js"
},
"files": [
"dist"
Expand Down
Loading