1111 types : [opened]
1212 paths :
1313 - ' packages/**'
14+ - ' apps/www/src/registry/**'
1415
1516jobs :
1617 create-changeset :
1718 # Only respond to @claude changeset mentions from authorized users in PRs
18- # OR when packages are modified without changesets
19+ # OR when packages/registry are modified without changesets/changelog updates
1920 if : |
2021 (
2122 (
@@ -42,33 +43,47 @@ jobs:
4243 with :
4344 fetch-depth : 0
4445
45- - name : Check for package changes without changesets
46+ - name : Check for package/registry changes without updates
4647 id : check-changes
4748 if : github.event_name == 'pull_request'
4849 run : |
49- # Get list of modified package files
50+ # Get list of modified files
5051 PACKAGE_CHANGES=$(git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} | grep '^packages/')
52+ REGISTRY_CHANGES=$(git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} | grep '^apps/www/src/registry/')
5153
54+ NEEDS_CHANGESET="false"
55+ NEEDS_CHANGELOG="false"
56+
57+ # Check package changes
5258 if [ -n "$PACKAGE_CHANGES" ]; then
5359 # Check if any changeset files were created
5460 CHANGESET_FILES=$(git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} | grep '^.changeset/')
5561
5662 if [ -z "$CHANGESET_FILES" ]; then
57- echo "::set-output name=needs_changeset:: true"
63+ NEEDS_CHANGESET=" true"
5864 echo "Found package changes without corresponding changeset files"
59- else
60- echo "::set-output name=needs_changeset::false"
61- echo "Changeset files already exist"
6265 fi
63- else
64- echo "::set-output name=needs_changeset::false"
65- echo "No package changes detected"
6666 fi
6767
68- - name : Create Changeset
68+ # Check registry changes
69+ if [ -n "$REGISTRY_CHANGES" ]; then
70+ # Check if changelog was updated
71+ CHANGELOG_CHANGES=$(git diff --name-only ${{ github.event.pull_request.base.sha }} ${{ github.event.pull_request.head.sha }} | grep '^docs/components/changelog.mdx')
72+
73+ if [ -z "$CHANGELOG_CHANGES" ]; then
74+ NEEDS_CHANGELOG="true"
75+ echo "Found registry changes without changelog update"
76+ fi
77+ fi
78+
79+ # Set outputs
80+ echo "::set-output name=needs_changeset::$NEEDS_CHANGESET"
81+ echo "::set-output name=needs_changelog::$NEEDS_CHANGELOG"
82+
83+ - name : Create Changeset/Update Changelog
6984 if : |
7085 github.event_name != 'pull_request' ||
71- (github.event_name == 'pull_request' && steps.check-changes.outputs.needs_changeset == 'true')
86+ (github.event_name == 'pull_request' && ( steps.check-changes.outputs.needs_changeset == 'true' || steps.check-changes.outputs.needs_changelog == 'true') )
7287 uses : grll/claude-code-action@beta
7388 with :
7489 use_oauth : true
@@ -77,12 +92,13 @@ jobs:
7792 claude_expires_at : ${{ secrets.CLAUDE_EXPIRES_AT }}
7893 timeout_minutes : ' 60'
7994 direct_prompt : |
80- You are tasked with creating changesets for the Plate project. Please follow these guidelines:
95+ You are tasked with creating changesets and updating the changelog for the Plate project. Please follow these guidelines:
8196
8297 **Primary Reference:**
8398 - Follow the Changeset Guide (.claude/commands/changeset.md) for structure, naming, and writing style
99+ - For registry changes, update docs/components/changelog.mdx
84100
85- **Changeset Standards:**
101+ **Changeset Standards (for package changes) :**
86102 - Use descriptive file naming: `[package]-[change-type].md`
87103 - Include proper YAML frontmatter with affected packages and change types
88104 - Write clear, concise descriptions using past tense verbs
@@ -91,6 +107,13 @@ jobs:
91107 - Use code blocks to show "Before" and "After" examples
92108 - Create separate changeset files for each distinct change type (major/minor/patch)
93109
110+ **Changelog Standards (for registry changes):**
111+ - Update docs/components/changelog.mdx
112+ - Follow the existing format and style
113+ - Document component changes, additions, or removals
114+ - Include any breaking changes or migration notes
115+ - Use consistent version numbering
116+
94117 **Change Type Guidelines:**
95118 - **major**: Breaking changes requiring user code updates
96119 - **minor**: New features that are backward-compatible
@@ -107,5 +130,6 @@ jobs:
107130 - Create changeset files in `.changeset/` directory
108131 - Use descriptive names that indicate package and change type
109132 - One file per distinct change to enable proper SemVer bumping
133+ - Update changelog.mdx for registry component changes
110134
111- Please analyze the changes in this PR and create appropriate changeset files following the guide.
135+ Please analyze the changes in this PR and create appropriate changeset files and/or update the changelog following the guide.
0 commit comments