Skip to content

Commit 9b732db

Browse files
authored
🤖 ci: fix fmt:check markdown coverage (#60)
## Summary - ensure Prettier globs cover docs and test sources so `fmt` and `fmt:check` see the same files - rename the helper to `run_prettier` for clarity - commit the resulting doc formatting from the expanded glob ## Testing - bun run fmt - bun run fmt:check
1 parent f316a86 commit 9b732db

File tree

2 files changed

+18
-15
lines changed

2 files changed

+18
-15
lines changed

docs/context-management.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@ Commands for managing conversation history length and token usage.
44

55
## Comparison
66

7-
| Feature | `/clear` | `/truncate` | `/compact` |
8-
|---------|----------|------------|------------|
9-
| **Speed** | Instant | Instant | Slower (uses AI) |
10-
| **Context Preservation** | None | Temporal | Intelligent |
11-
| **Cost** | Free | Free | Uses API tokens |
12-
| **Reversible** | No | No | No |
7+
| Feature | `/clear` | `/truncate` | `/compact` |
8+
| ------------------------ | -------- | ----------- | ---------------- |
9+
| **Speed** | Instant | Instant | Slower (uses AI) |
10+
| **Context Preservation** | None | Temporal | Intelligent |
11+
| **Cost** | Free | Free | Uses API tokens |
12+
| **Reversible** | No | No | No |
1313

1414
## `/clear` - Clear All History
1515

16-
Remove all messages from conversation history.
16+
Remove all messages from conversation history.
1717

1818
### Syntax
1919

@@ -59,7 +59,7 @@ Basic compaction with default settings.
5959
Limit summary to 1000 output tokens.
6060

6161
```
62-
/compact 2000 next up, we're adding a dark theme
62+
/compact 2000 next up, we're adding a dark theme
6363
```
6464

6565
Compact with token limit and custom instructions.
@@ -101,5 +101,3 @@ Remove oldest 50% of messages.
101101
- About as fast as `/clear`
102102
- `/truncate 100` is equivalent to `/clear`
103103
- **Irreversible** - messages are permanently removed
104-
105-

scripts/fmt.sh

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ PROJECT_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)"
77

88
cd "$PROJECT_ROOT"
99

10-
PRETTIER_PATTERNS=("src/**/*.{ts,tsx,js,jsx,json}" "*.{json,md}")
10+
PRETTIER_PATTERNS=(
11+
"src/**/*.{ts,tsx,js,jsx,json}"
12+
"tests/**/*.{ts,tsx,js,jsx,json}"
13+
"docs/**/*.{md,mdx}"
14+
"*.{json,md}"
15+
)
1116

12-
format_typescript() {
17+
run_prettier() {
1318
local mode="$1"
1419
if [ "$mode" = "--check" ]; then
1520
echo "Checking TypeScript/JSON/Markdown formatting..."
@@ -38,12 +43,12 @@ format_shell() {
3843
}
3944

4045
if [ "$1" = "--check" ]; then
41-
format_typescript --check
46+
run_prettier --check
4247
elif [ "$1" = "--shell" ]; then
4348
format_shell
4449
elif [ "$1" = "--all" ]; then
45-
format_typescript
50+
run_prettier
4651
format_shell
4752
else
48-
format_typescript
53+
run_prettier
4954
fi

0 commit comments

Comments
 (0)