Skip to content
Open
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
28 changes: 24 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,33 @@ jobs:
run: pnpm install
- name: Build
run: pnpm -r build
- name: Consume changesets and publish
- name: Consume changesets
run: |
npx changeset version
npx changeset publish --tag "$DIST_TAG"
git push origin main --follow-tags

# Bump the monorepo root version so tags always advance.
# The root is private (never published) and drives the v* tag.
npm version minor --no-git-tag-version
git commit --amend --no-edit

- name: Publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
DIST_TAG: ${{ inputs.distTag }}
run: npx changeset publish --tag "${DIST_TAG}" --no-git-tag

- name: Push version commit
run: git push origin main

- name: GitHub Release & Tag
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
TAG="v$(jq -r '.version' package.json)"
git tag "$TAG"
git push origin "$TAG"
gh release create "$TAG" \
--title "$TAG" \
--generate-notes \
--verify-tag
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
"name": "devtools-monorepo",
"version": "10.6.1",
"private": true,
"type": "module",
"scripts": {
"build": "pnpm -r build",
Expand Down
Loading