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
18 changes: 13 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,33 @@ jobs:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1

- name: Setup Node.js
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020
with:
node-version: 24
cache: npm
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.14

- name: Install dependencies
run: bun install --frozen-lockfile
run: npm ci

- name: Run ESLint
run: bun run lint
run: npm run lint

- name: Run Prettier check
run: bun run format:check
run: npm run format:check

- name: Run unit tests
run: bun test
run: npm test

- name: Verify version sync
run: bun run release:check
run: npm run release:check

- name: Smoke test CLI help
run: bun bin/pkgmap.js --help
14 changes: 5 additions & 9 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,10 @@ jobs:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1

- name: Setup Node.js
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
node-version: 24
registry-url: https://registry.npmjs.org
cache: npm
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
bun-version: 1.3.14

- name: Install dependencies
run: npm ci
Expand All @@ -49,12 +45,12 @@ jobs:
run: npm run release:check

- name: Smoke test CLI help
run: node bin/pkgmap.js --help
run: bun bin/pkgmap.js --help

- name: Publish to npm (skip if already published)
shell: bash
run: |
PACKAGE_VERSION=$(node -p "require('./package.json').version")
PACKAGE_VERSION=$(bun -e "console.log(JSON.parse(require('fs').readFileSync('package.json', 'utf8')).version)")
PUBLISHED=$(npm view @mulham28/pkgmap@$PACKAGE_VERSION version 2>/dev/null || true)

if [ "$PUBLISHED" = "$PACKAGE_VERSION" ]; then
Expand Down