diff --git a/.changeset/config.json b/.changeset/config.json index 07240be..d8b0b65 100644 --- a/.changeset/config.json +++ b/.changeset/config.json @@ -9,5 +9,5 @@ "baseBranch": "main", "updateInternalDependencies": "patch", "ignore": ["create-db-worker", "claim-db-worker"], - "linked": [["create-db", "create-db-worker", "claim-db-worker"]] + "linked": [["create-db", "create-pg", "create-postgres"]] } diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4e093af..db85453 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -32,6 +32,11 @@ jobs: - name: 🔧 Install dependencies run: pnpm install + - name: 🔧 Install jq + run: | + sudo apt-get update + sudo apt-get install -y jq + - name: ✔️ Check for pending changesets run: | pnpm changeset status --output status.json @@ -39,9 +44,6 @@ jobs: echo "❌ No changesets found. Please run 'pnpm changeset' and add a summary." >&2 exit 1 fi - # install jq if missing - - name: 🔧 Install jq - run: sudo apt-get update && sudo apt-get install -y jq - name: 🔄 Bump versions & generate changelogs id: bump @@ -54,15 +56,12 @@ jobs: done - name: 💾 Commit & push version bump - id: commit env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - # collect all bumped package@version - VERSIONS=$(jq -r '.packages | to_entries[] - | select(.value.changes != null) - | .value.name + "@" + .value.packageJSON.version' - status.json | paste -sd ', ' -) + git config user.name "github-actions[bot]" + git config user.email "github-actions[bot]@users.noreply.github.com" + VERSIONS=$(jq -r '.releases[] | .name + "@" + .newVersion' status.json | paste -sd ", " -) git commit -am "chore(release): bump $VERSIONS [skip ci]" || echo "no version changes" git push origin main --follow-tags @@ -71,7 +70,6 @@ jobs: echo "# Release ${{ steps.bump.outputs.newVersion }}" > AGGREGATED_CHANGELOG.md for pkg in $WORKSPACES; do echo "## $pkg" >> AGGREGATED_CHANGELOG.md - # pull just the section for the new version from each CHANGELOG sed -n "/^## ${{ steps.bump.outputs.newVersion }}/,/^## /p" $pkg/CHANGELOG.md \ | sed '1d;$d' \ >> AGGREGATED_CHANGELOG.md @@ -90,13 +88,9 @@ jobs: - name: 🔑 Configure npm auth run: echo "//registry.npmjs.org/:_authToken=${{ secrets.CREATE_DB_TOKEN_NPM }}" > ~/.npmrc - - name: 🚀 Publish all real releases + - name: 🚀 Publish CLIs run: | - for pkg in $WORKSPACES; do - cd "$pkg" - pnpm publish --access public - cd - >/dev/null - done + pnpm -r --filter "{create-db,create-pg,create-postgres}" publish --access public # — CF production deploys commented out; we rely on existing worker URLs # - name: ☁️ Deploy create-db-worker (production) diff --git a/claim-db-worker/package.json b/claim-db-worker/package.json index a050031..bd94cbd 100644 --- a/claim-db-worker/package.json +++ b/claim-db-worker/package.json @@ -1,5 +1,5 @@ { - "name": "claim-worker", + "name": "claim-db-worker", "version": "0.0.2", "private": true, "scripts": { diff --git a/create-db-worker/package.json b/create-db-worker/package.json index 5ac517c..a9bd0fc 100644 --- a/create-db-worker/package.json +++ b/create-db-worker/package.json @@ -1,5 +1,5 @@ { - "name": "worker", + "name": "create-db-worker", "version": "0.0.2", "private": true, "scripts": { diff --git a/create-db/CHANGELOG.md b/create-db/CHANGELOG.md new file mode 100644 index 0000000..2209194 --- /dev/null +++ b/create-db/CHANGELOG.md @@ -0,0 +1,7 @@ +# create-db + +## 0.0.3 + +### Patch Changes + +- fix: clearing change log versions diff --git a/create-db/package.json b/create-db/package.json index b432b5f..304db73 100644 --- a/create-db/package.json +++ b/create-db/package.json @@ -1,6 +1,6 @@ { "name": "create-db", - "version": "0.0.2", + "version": "0.0.3", "description": "Instantly create a temporary Prisma Postgres database with one command, then claim and persist it in your Prisma Data Platform project when ready.", "main": "index.js", "author": "", diff --git a/create-pg/CHANGELOG.md b/create-pg/CHANGELOG.md new file mode 100644 index 0000000..27e8972 --- /dev/null +++ b/create-pg/CHANGELOG.md @@ -0,0 +1,9 @@ +# create-pg + +## 0.0.3 + +### Patch Changes + +- fix: clearing change log versions +- Updated dependencies + - create-db@0.0.3 diff --git a/create-pg/package.json b/create-pg/package.json index 491a5e3..69a6c82 100644 --- a/create-pg/package.json +++ b/create-pg/package.json @@ -1,6 +1,6 @@ { "name": "create-pg", - "version": "0.0.2", + "version": "0.0.3", "description": "Instantly create a temporary Prisma Postgres database with one command, then claim and persist it in your Prisma Data Platform project when ready.", "main": "index.js", "author": "", diff --git a/create-postgres/CHANGELOG.md b/create-postgres/CHANGELOG.md new file mode 100644 index 0000000..8a7822b --- /dev/null +++ b/create-postgres/CHANGELOG.md @@ -0,0 +1,9 @@ +# create-postgres + +## 0.0.3 + +### Patch Changes + +- fix: clearing change log versions +- Updated dependencies + - create-db@0.0.3 diff --git a/create-postgres/package.json b/create-postgres/package.json index 2869c85..07236a5 100644 --- a/create-postgres/package.json +++ b/create-postgres/package.json @@ -1,6 +1,6 @@ { "name": "create-postgres", - "version": "0.0.2", + "version": "0.0.3", "description": "Instantly create a temporary Prisma Postgres database with one command, then claim and persist it in your Prisma Data Platform project when ready.", "main": "index.js", "author": "", diff --git a/status.json b/status.json new file mode 100644 index 0000000..291627a --- /dev/null +++ b/status.json @@ -0,0 +1,51 @@ +{ + "changesets": [ + { + "releases": [ + { + "name": "create-db", + "type": "patch" + }, + { + "name": "create-pg", + "type": "patch" + }, + { + "name": "create-postgres", + "type": "patch" + } + ], + "summary": "fix: clearing change log versions", + "id": "angry-humans-call" + } + ], + "releases": [ + { + "name": "create-db", + "type": "patch", + "oldVersion": "0.0.2", + "changesets": [ + "angry-humans-call" + ], + "newVersion": "0.0.3" + }, + { + "name": "create-pg", + "type": "patch", + "oldVersion": "0.0.2", + "changesets": [ + "angry-humans-call" + ], + "newVersion": "0.0.3" + }, + { + "name": "create-postgres", + "type": "patch", + "oldVersion": "0.0.2", + "changesets": [ + "angry-humans-call" + ], + "newVersion": "0.0.3" + } + ] +} \ No newline at end of file