-
Notifications
You must be signed in to change notification settings - Fork 24
feat: add changeset-based release notes mechanism #71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| # Changesets | ||
|
|
||
| Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works | ||
| with multi-package repos, or single-package repos to help you version and publish your code. You can | ||
| find the full documentation for it [in the changesets repo](https://github.com/changesets/changesets). | ||
|
|
||
| ## Adding a changeset | ||
|
|
||
| To add a changeset, run `bun run changeset` in the root of the repository. This will prompt you to: | ||
|
|
||
| 1. Select which packages should be updated | ||
| 2. Choose the version bump type (major, minor, or patch) | ||
| 3. Write a summary of the changes | ||
|
|
||
| The changeset file will be created in this directory and should be committed with your PR. | ||
|
|
||
| ## How it works | ||
|
|
||
| 1. When you create a PR with code changes, include a changeset describing the change | ||
| 2. When PRs are merged to `dev`, the changeset-release workflow will create or update a "Version Bump" PR | ||
| 3. When the Version Bump PR is merged, it will trigger a release with the generated changelog |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| { | ||
| "$schema": "https://unpkg.com/@changesets/config@3.0.4/schema.json", | ||
| "changelog": ["@changesets/changelog-github", { "repo": "Kilo-Org/kilo" }], | ||
| "commit": false, | ||
| "fixed": [], | ||
| "linked": [], | ||
| "access": "restricted", | ||
| "baseBranch": "dev", | ||
| "updateInternalDependencies": "patch", | ||
| "ignore": [] | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| # kilocode_change - new file | ||
| name: Changeset Release | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - dev | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
| changeset-pr-version-bump: | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| steps: | ||
| - name: Git Checkout | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 0 | ||
| ref: dev | ||
|
|
||
| - name: Setup Bun | ||
| uses: oven-sh/setup-bun@v2 | ||
| with: | ||
| bun-version: latest | ||
|
|
||
| - name: Install Dependencies | ||
| run: bun install | ||
|
|
||
| - name: Changeset Pull Request | ||
| id: changesets | ||
| uses: changesets/action@v1 | ||
| with: | ||
| commit: "changeset version bump" | ||
| title: "Changeset version bump" | ||
| version: bun run changeset:version | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,6 +2,10 @@ name: publish | |
| run-name: "${{ format('release {0}', inputs.bump) }}" | ||
|
|
||
| on: | ||
| # kilocode_change start - trigger on changeset PR merge | ||
| pull_request: | ||
| types: [closed] | ||
| # kilocode_change end | ||
| push: | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. SUGGESTION: Workflow triggers on With the current job |
||
| branches: | ||
| - dev | ||
|
|
@@ -31,8 +35,13 @@ permissions: | |
| jobs: | ||
| publish: | ||
| runs-on: depot-ubuntu-24.04-4 | ||
| # kilocode_change start - disabled for kilo-cli fork (OpenCode npm/AUR publishing) | ||
| if: false | ||
| # kilocode_change start - trigger on changeset PR merge or workflow_dispatch | ||
| if: > | ||
| ( github.event_name == 'pull_request' && | ||
| github.event.pull_request.merged == true && | ||
| github.event.pull_request.base.ref == 'dev' && | ||
| contains(github.event.pull_request.title, 'Changeset version bump') ) || | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. WARNING: Release trigger relies only on PR title substring
|
||
| github.event_name == 'workflow_dispatch' | ||
| # kilocode_change end - original: if: github.repository == 'Kilo-Org/kilo' | ||
| steps: | ||
| - uses: actions/checkout@v3 | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
WARNING: Non-deterministic Bun version (
latest) can break the release workflowUsing
bun-version: latestcan introduce unexpected CI breakages when Bun releases. Pin to the repo's declared Bun version (e.g. thepackageManagerversion) to keep releases reproducible.