Skip to content

Commit ee3adca

Browse files
committed
ci
1 parent 4b17767 commit ee3adca

File tree

4 files changed

+27
-43
lines changed

4 files changed

+27
-43
lines changed

.claude/commands/changeset.md

Lines changed: 11 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,22 @@ The frontmatter is enclosed by ---` lines. It lists each affected package and it
4444
**Important Note on SemVer Bumping and Multiple Changesets:**
4545

4646
- Each distinct change (breaking, feature, fix) for a package **MUST** have its own changeset file.
47+
- A single changeset file **MUST** contain only ONE package in its frontmatter.
4748
- For example, if you make a breaking API change, add a new feature, and fix a bug in `@platejs/core` for an upcoming release, you will create **three separate changeset files**:
4849
1. One file marked `major` for `@platejs/core` detailing only the breaking change.
4950
2. One file marked `minor` for `@platejs/core` detailing only the new feature.
5051
3. One file marked `patch` for `@platejs/core` detailing only the bug fix.
5152
- The versioning tool will look at all pending changesets for a package. If there's at least one `major` file, the package gets a major version bump, and all changes (from major, minor, and patch files) are included in that release. If no `major` but at least one `minor`, it gets a minor bump, and so on.
5253

54+
**Example: Multiple Changes, Multiple Packages**
55+
56+
- If a PR adds a `minor` feature to `@platejs/core` and a `patch` fix to `@platejs/utils`, you MUST create TWO separate files:
57+
58+
1. `core-minor.md` (containing only `'@platejs/core': minor`)
59+
2. `utils-patch.md` (containing only `'@platejs/utils': patch`)
60+
61+
- If a PR adds `minor` features to both `@platejs/core` and `@platejs/utils`, you MUST create TWO separate `minor` changeset files, one for each package. DO NOT group them in a single file.
62+
5363
**Example (Illustrating multiple files for one package):**
5464

5565
File 1: `core-major.md`
@@ -144,29 +154,4 @@ This section explains **what changed for the user** and **how they should adapt*
144154
```
145155
`
146156
147-
- **New Features / Enhancements (`minor` changeset):**
148-
149-
- - Added `useNewHook()` for managing X.
150-
```ts
151-
const value = useNewHook(editor);
152-
```
153-
- - Added `newOption` to `PluginName` options for Y.
154-
- - Added `editor.meta.containerTypes`: an array of container node types derived from enabled plugins that have `plugin.node.isContainer = true`.
155-
- - Updated `editor.api.fragment` to automatically use `editor.meta.containerTypes` as a default for the `containerTypes` option when not explicitly provided.
156-
157-
- **Bug Fixes (`patch` changeset):**
158-
159-
- - Fixed an issue where typing at the end of a link would not extend the link mark.
160-
- - Corrected the behavior of `someFunction()` to prevent crashes with empty inputs.
161-
162-
- **Removals (Always `major`):**
163-
- - Removed `obsoleteFunction()` from `**PackageName**`. There is no direct replacement.
164-
- - Removed default shortcuts for `**SomePlugin**`. Configure them via `editor.configure(SomePlugin, { shortcuts: { ... } })` if needed.
165-
166-
**Writing Style:**
167-
168-
- **Clarity and Precision:** Be unambiguous.
169-
- **Action-Oriented:** Use past tense verbs to describe changes. Use imperative mood for migration steps (e.g., "- Replace...", "- Update...").
170-
- **User-Focused:** Prioritize information crucial for developers integrating the changes.
171-
172-
By strictly following these guidelines, we will maintain a high-quality, accurate, and developer-friendly changelog where each change is distinctly categorized.
157+
- \*\*New Features / Enhancements (`

.github/workflows/claude-changeset.yml

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,6 @@ name: Claude Changeset
33
on:
44
issue_comment:
55
types: [created]
6-
pull_request_review_comment:
7-
types: [created]
8-
pull_request_review:
9-
types: [submitted]
106
pull_request:
117
types: [opened]
128
paths:
@@ -15,14 +11,12 @@ on:
1511

1612
jobs:
1713
create-changeset:
18-
# Only respond to @claude changeset mentions from authorized users in PRs
14+
# Only respond to /changeset mentions from authorized users in PRs
1915
# OR when packages/registry are modified without changesets/changelog updates
2016
if: |
2117
(
2218
(
23-
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude changeset') && github.event.issue.pull_request) ||
24-
(github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude changeset')) ||
25-
(github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude changeset'))
19+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '/changeset') && github.event.issue.pull_request)
2620
) && (
2721
github.actor == 'zbeyens' ||
2822
github.actor == 'felixfeng33'
@@ -98,6 +92,13 @@ jobs:
9892
- Follow the Changeset Guide (.claude/commands/changeset.md) for structure, naming, and writing style
9993
- For registry changes, update docs/components/changelog.mdx
10094
95+
**Critical Requirement: Separate Changesets**
96+
- You MUST create a separate changeset file for EACH package AND EACH change type (major, minor, patch).
97+
- A single changeset file MUST contain only ONE package in its frontmatter.
98+
- **Example 1:** If a PR adds a `minor` feature to `@platejs/core` and a `patch` fix to `@platejs/utils`, you MUST create TWO files: one for `@platejs/core` (minor) and one for `@platejs/utils` (patch).
99+
- **Example 2:** If a PR adds `minor` features to both `@platejs/core` and `@platejs/utils`, you MUST create TWO separate `minor` changeset files, one for each package.
100+
- This is essential for correct semantic versioning. DO NOT group multiple packages in one file.
101+
101102
**Changeset Standards (for package changes):**
102103
- Use descriptive file naming: `[package]-[change-type].md`
103104
- Include proper YAML frontmatter with affected packages and change types
@@ -132,4 +133,8 @@ jobs:
132133
- One file per distinct change to enable proper SemVer bumping
133134
- Update changelog.mdx for registry component changes
134135
136+
**Changeset required when updating packages**
137+
- Updating `docs/components/changelog.mdx` is required when updating `apps/www/src/registry`
138+
- Use `/docs` command to update documentation
139+
135140
Please analyze the changes in this PR and create appropriate changeset files and/or update the changelog following the guide.

.github/workflows/claude-docs.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,13 @@ name: Claude Docs
33
on:
44
issue_comment:
55
types: [created]
6-
pull_request_review_comment:
7-
types: [created]
8-
pull_request_review:
9-
types: [submitted]
106

117
jobs:
128
update-docs:
13-
# Only respond to @claude docs mentions from authorized users in PRs
9+
# Only respond to /docs mentions from authorized users in PRs
1410
if: |
1511
(
16-
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude docs') && github.event.issue.pull_request) ||
17-
(github.event_name == 'pull_request_review_comment' && contains(github.event.comment.body, '@claude docs')) ||
18-
(github.event_name == 'pull_request_review' && contains(github.event.review.body, '@claude docs'))
12+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '/docs') && github.event.issue.pull_request)
1913
) && (
2014
github.actor == 'zbeyens' ||
2115
github.actor == 'felixfeng33'

.github/workflows/claude.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
if: |
1717
(
1818
(
19-
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude') && !contains(github.event.comment.body, '@claude changeset') && !contains(github.event.comment.body, '@claude docs')) ||
19+
(github.event_name == 'issue_comment' && contains(github.event.comment.body, '@claude')) ||
2020
(github.event_name == 'issues' && contains(github.event.issue.body, '@claude')) ||
2121
(github.event_name == 'discussion' && contains(github.event.discussion.body, '@claude')) ||
2222
(github.event_name == 'discussion_comment' && contains(github.event.comment.body, '@claude'))

0 commit comments

Comments
 (0)