Skip to content

Commit 4b8c6eb

Browse files
authored
chore: add cursor rule for release notes (#9033)
* chore: add cursor rule for release notes * update cursor rules * add space
1 parent 7d3f499 commit 4b8c6eb

File tree

3 files changed

+85
-0
lines changed

3 files changed

+85
-0
lines changed

.cursor/rules/add-subheadings.mdc

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
alwaysApply: false
3+
---
4+
5+
# Step 3: Add sub-headings
6+
7+
Within the Enhancements, Fixes, and Under Construction categories, group commits by UI component under sub-headings.
8+
9+
### Sub-heading rules:
10+
- Use sub-headings ONLY for:
11+
- Enhancements
12+
- Fixes
13+
- Under Construction
14+
- Do NOT create sub-headings for:
15+
- Documentation
16+
- To Be Categorized
17+
- S2
18+
- Sub-headings should be in alphabetical order
19+
- Use "Miscellaneous" as a sub-heading for commits that do not belong to a specific component
20+
- Each category can have its own Miscellaneous sub-heading
21+
- Write sub-headings and commits as unordered lists using a hyphen (-)
22+
- Do NOT bold the sub-heading text
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
---
2+
alwaysApply: false
3+
---
4+
5+
# Step 1: Categorize commits
6+
7+
Sort ALL commit messages into one of six main categories. The main categories are the following:
8+
- Enhancements
9+
- Fixes
10+
- Documentation
11+
- Under Construction
12+
- To Be Categorized
13+
- S2
14+
15+
Before categorizing commits into other groups, check whether each commit should be classified as “Under Construction.”
16+
- Follow the steps below in order:
17+
1. Identify pre-release packages
18+
- Use a command such as grep to scan the repository for package versions that include prerelease identifiers (e.g., alpha, beta, rc)
19+
2. Extract component keywords from commit messages
20+
- Parse each commit message to identify possible component names
21+
- Normalize these keywords (e.g., lowercase, remove punctuation) for easier comparison.
22+
3. Compare extracted keywords with pre-release packages
23+
- If any keyword matches a package in the list, mark the commit as Under Construction.
24+
4. Check for explicit prerelease keywords in commit text
25+
- If the commit message directly includes alpha, beta, or rc, classify it as Under Construction, regardless of package matches.
26+
27+
Next, categorize the remaining commits not categorized as "Under Construction". Use the following keywords to determine the category:
28+
| Keyword | Category |
29+
|----------------------------|----------|
30+
| feat | Enhancements|
31+
| fix | Fixes |
32+
| docs | Documentation |
33+
| chore, revert, bump, build | To Be Categorized |
34+
| S2 | S2 |
35+
36+
Do not duplicate commits. In terms of priority, it should be Under Construction > S2 > To Be Categorized > Enhancements > Fixes > Documentation
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
alwaysApply: false
3+
---
4+
5+
You are a expert technical writer for front-end development.
6+
7+
# Step 2: Rewrite commit messages
8+
9+
Original format: Type (Scope): Summary of changes - [@username](link to username) - [PR](link to PR)
10+
New Format: Summary of changes - [@username](link to username) - [PR](link to PR)
11+
12+
### General Guidelines:
13+
- Keep the summary as a single, grammatically correct sentence
14+
- Verbs should be first person present tense but do NOT include the subject (e.g. I)
15+
- The message should be concise and easy to read
16+
- Wrap any camelCase or code-like terms (e.g. onClick, onAction, isDisabled) in backticks (``)
17+
- Do NOT use backticks for component names
18+
- Replace specific terms:
19+
- RAC -> React Aria
20+
- V3 -> React Spectrum
21+
- ALWAYS capitalize UI component names
22+
- Example:
23+
- toast -> Toast
24+
- inline alert -> InlineAlert
25+
26+
### Component Names to Capitalize:
27+
Accordion, Autocomplete, Badge, Breadcrumbs, Buttons, Calendar, Checkbox, CheckboxGroup, Collections, ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker, ColorWheel, ComboBox, Date and Time, DateField, DatePicker, DateRangePicker, Dialog, Disclosure, DisclosureGroup, Drag and Drop, DropZone, FileTrigger, Form, InlineAlert, Link, Listbox, ListView, Menu, Meter, Modal, NotificationBadge, NumberField, Picker, ProgressBar, ProgressCircle, RadioGroup, RangeCalendar, SearchField, Select, Slider, StatusLight, Switch, Table, Tabs, TagGroup, TextArea, TextField, TimeField, Toast, ToggleButton, ToggleButtonGroup, Tooltip, Tree, Virtualizer.

0 commit comments

Comments
 (0)