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
13 changes: 9 additions & 4 deletions .github/workflows/create-release-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,12 @@ jobs:
pull-requests: write
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
with:
persist-credentials: false

- name: Install pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
with:
persist-credentials: false

Expand All @@ -34,11 +39,11 @@ jobs:
with:
node-version: 'lts/*'

# No need to install dependencies - npm version works without them
# No need to install dependencies - pnpm version works without them
- name: Version bump
id: version
run: |
npm version "$VERSION_TYPE" --no-git-tag-version
pnpm version "$VERSION_TYPE" --no-git-tag-version
VERSION=$(jq -r '.version' package.json)
echo "version=$VERSION" >> $GITHUB_OUTPUT
env:
Expand Down Expand Up @@ -97,7 +102,7 @@ jobs:
commit-message: "chore: release v${{ steps.version.outputs.version }}"
add-paths: |
package.json
yarn.lock
pnpm.lock
labels: |
Type: Release
assignees: ${{ github.actor }}
Expand Down
24 changes: 10 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ jobs:
pull-requests: write # PR comment
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
with:
persist-credentials: false

- name: Install pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
with:
persist-credentials: false

Expand Down Expand Up @@ -65,28 +70,19 @@ jobs:
node-version: 'lts/*'
registry-url: 'https://registry.npmjs.org'

- name: Ensure npm 11.5.1 or later is installed
if: steps.tag-check.outputs.exists == 'false'
run: |
NPM_VERSION=$(npm -v)
echo "Current npm version: $NPM_VERSION"
if ! npx semver -r ">=11.5.1" "$NPM_VERSION"; then
echo "npm version $NPM_VERSION is too old. Installing latest npm..."
npm install -g npm@latest
echo "Updated npm version: $(npm -v)"
fi
# pnpm is already installed via pnpm/action-setup

- name: Install dependencies
if: steps.tag-check.outputs.exists == 'false'
run: yarn install --frozen-lockfile
run: pnpm install --frozen-lockfile

- name: Build package
if: steps.tag-check.outputs.exists == 'false'
run: yarn run build
run: pnpm run build

- name: Publish to npm with provenance
if: steps.tag-check.outputs.exists == 'false'
run: npm publish --provenance --access public
run: pnpm publish --provenance --access public

- name: Create GitHub Release with tag
id: create-release
Expand Down
15 changes: 10 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,22 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [ 16, 18 ]
node-version: [ 20, 22, 24 ]
steps:
- name: checkout
uses: actions/checkout@ee0669bd1cc54295c223e0bb666b733df41de1c5 # v2.7.0
uses: actions/checkout@ee0669bd1cc54295c223e0bb666b733df41de1c5
with:
persist-credentials: false

- name: Install pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
with:
persist-credentials: false
- name: setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@f1f314fca9dfce2769ece7d933488f076716723e # v1.4.6
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
with:
node-version: ${{ matrix.node-version }}
- name: Install
run: yarn install
run: pnpm install
- name: Test
run: yarn run build
run: pnpm run build
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,6 @@
"ts-node": "^10.9.1",
"ts-node-test-register": "^10.0.0",
"typescript": "^4.9.4"
}
},
"packageManager": "pnpm@10.15.1+sha512.34e538c329b5553014ca8e8f4535997f96180a1d0f614339357449935350d924e22f8614682191264ec33d1462ac21561aff97f6bb18065351c162c7e8f6de67"
}
Loading
Loading