@nomad-e/bluma-cli 0.26.3 → 2026.27.0-darwin-x64
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +189 -70
- package/README.md +2 -162
- package/THIRD-PARTY-NOTICES.txt +46201 -0
- package/bin/bluma-core +0 -0
- package/package.json +24 -124
- package/third-party/option-ext/.cargo_vcs_info.json +6 -0
- package/third-party/option-ext/Cargo.toml +22 -0
- package/third-party/option-ext/LICENSE.txt +373 -0
- package/third-party/option-ext/README.md +67 -0
- package/third-party/option-ext/src/impl.rs +20 -0
- package/third-party/option-ext/src/lib.rs +71 -0
- package/assets/bg.png +0 -0
- package/assets/bg1.png +0 -0
- package/assets/bluma.png +0 -0
- package/assets/image.png +0 -0
- package/dist/assets/bg.png +0 -0
- package/dist/assets/bg1.png +0 -0
- package/dist/assets/bluma.png +0 -0
- package/dist/assets/image.png +0 -0
- package/dist/config/native_tools.json +0 -1151
- package/dist/config/plan_mode_instructions.md +0 -218
- package/dist/config/skills/factorai-sh/SKILL.md +0 -98
- package/dist/config/skills/git-commit/LICENSE.txt +0 -18
- package/dist/config/skills/git-commit/SKILL.md +0 -300
- package/dist/config/skills/git-commit/references/REFERENCE.md +0 -253
- package/dist/config/skills/git-commit/scripts/validate_commit_msg.py +0 -163
- package/dist/config/skills/git-pr/LICENSE.txt +0 -18
- package/dist/config/skills/git-pr/SKILL.md +0 -293
- package/dist/config/skills/git-pr/references/REFERENCE.md +0 -256
- package/dist/config/skills/git-pr/scripts/validate_commits.py +0 -120
- package/dist/config/skills/git-release/LICENSE.txt +0 -18
- package/dist/config/skills/git-release/SKILL.md +0 -408
- package/dist/config/skills/pdf/LICENSE.txt +0 -26
- package/dist/config/skills/pdf/SKILL.md +0 -736
- package/dist/config/skills/pdf/references/DOCUMENT_TYPES.md +0 -59
- package/dist/config/skills/pdf/references/FORMS.md +0 -69
- package/dist/config/skills/pdf/references/REFERENCE.md +0 -52
- package/dist/config/skills/pdf/scripts/__pycache__/create_report.cpython-312.pyc +0 -0
- package/dist/config/skills/pdf/scripts/create_report.py +0 -936
- package/dist/config/skills/pdf/scripts/merge_pdfs.py +0 -48
- package/dist/config/skills/skill-creator/LICENSE.txt +0 -26
- package/dist/config/skills/skill-creator/SKILL.md +0 -229
- package/dist/config/skills/xlsx/LICENSE.txt +0 -18
- package/dist/config/skills/xlsx/SKILL.md +0 -340
- package/dist/config/skills/xlsx/references/REFERENCE.md +0 -337
- package/dist/config/skills/xlsx/scripts/office/__init__.py +0 -2
- package/dist/config/skills/xlsx/scripts/office/pack.py +0 -58
- package/dist/config/skills/xlsx/scripts/office/soffice.py +0 -180
- package/dist/config/skills/xlsx/scripts/office/unpack.py +0 -63
- package/dist/config/skills/xlsx/scripts/office/validate.py +0 -122
- package/dist/config/skills/xlsx/scripts/recalc.py +0 -152
- package/dist/main.js +0 -47932
- package/dist/native/bluma-clipboard.linux-x64-gnu.node +0 -0
- package/dist/native/index.d.ts +0 -38
- package/dist/native/index.js +0 -319
- package/dist/native/package.json +0 -38
- package/dist/scaffold/.eslintrc.json +0 -3
- package/dist/scaffold/app/globals.css +0 -46
- package/dist/scaffold/app/layout.tsx +0 -19
- package/dist/scaffold/app/page.tsx +0 -124
- package/dist/scaffold/components/ui/README.md +0 -12
- package/dist/scaffold/components/ui/accordion.jsx +0 -42
- package/dist/scaffold/components/ui/alert-dialog.jsx +0 -80
- package/dist/scaffold/components/ui/alert.jsx +0 -33
- package/dist/scaffold/components/ui/aspect-ratio.jsx +0 -5
- package/dist/scaffold/components/ui/avatar.jsx +0 -28
- package/dist/scaffold/components/ui/badge.jsx +0 -24
- package/dist/scaffold/components/ui/breadcrumb.jsx +0 -72
- package/dist/scaffold/components/ui/button.jsx +0 -40
- package/dist/scaffold/components/ui/calendar.jsx +0 -56
- package/dist/scaffold/components/ui/card.jsx +0 -38
- package/dist/scaffold/components/ui/carousel.jsx +0 -168
- package/dist/scaffold/components/ui/chart.jsx +0 -76
- package/dist/scaffold/components/ui/checkbox.jsx +0 -22
- package/dist/scaffold/components/ui/collapsible.jsx +0 -7
- package/dist/scaffold/components/ui/command.jsx +0 -100
- package/dist/scaffold/components/ui/context-menu.jsx +0 -137
- package/dist/scaffold/components/ui/dialog.jsx +0 -72
- package/dist/scaffold/components/ui/drawer.jsx +0 -68
- package/dist/scaffold/components/ui/dropdown-menu.jsx +0 -143
- package/dist/scaffold/components/ui/form.jsx +0 -88
- package/dist/scaffold/components/ui/hover-card.jsx +0 -22
- package/dist/scaffold/components/ui/input-otp.jsx +0 -49
- package/dist/scaffold/components/ui/input.jsx +0 -19
- package/dist/scaffold/components/ui/label.jsx +0 -15
- package/dist/scaffold/components/ui/menubar.jsx +0 -161
- package/dist/scaffold/components/ui/navigation-menu.jsx +0 -95
- package/dist/scaffold/components/ui/pagination.jsx +0 -77
- package/dist/scaffold/components/ui/popover.jsx +0 -25
- package/dist/scaffold/components/ui/progress.jsx +0 -19
- package/dist/scaffold/components/ui/radio-group.jsx +0 -29
- package/dist/scaffold/components/ui/resizable.jsx +0 -27
- package/dist/scaffold/components/ui/scroll-area.jsx +0 -31
- package/dist/scaffold/components/ui/select.jsx +0 -117
- package/dist/scaffold/components/ui/separator.jsx +0 -22
- package/dist/scaffold/components/ui/sheet.jsx +0 -81
- package/dist/scaffold/components/ui/skeleton.jsx +0 -7
- package/dist/scaffold/components/ui/slider.jsx +0 -19
- package/dist/scaffold/components/ui/sonner.jsx +0 -22
- package/dist/scaffold/components/ui/switch.jsx +0 -23
- package/dist/scaffold/components/ui/table.jsx +0 -61
- package/dist/scaffold/components/ui/tabs.jsx +0 -43
- package/dist/scaffold/components/ui/textarea.jsx +0 -18
- package/dist/scaffold/components/ui/toast.jsx +0 -85
- package/dist/scaffold/components/ui/toaster.jsx +0 -33
- package/dist/scaffold/components/ui/toggle-group.jsx +0 -41
- package/dist/scaffold/components/ui/toggle.jsx +0 -30
- package/dist/scaffold/components/ui/tooltip.jsx +0 -22
- package/dist/scaffold/hooks/use-toast.ts +0 -101
- package/dist/scaffold/lib/utils.ts +0 -6
- package/dist/scaffold/next.config.js +0 -5
- package/dist/scaffold/next.config.mjs +0 -15
- package/dist/scaffold/next.config.ts +0 -19
- package/dist/scaffold/package.json +0 -70
- package/dist/scaffold/postcss.config.js +0 -6
- package/dist/scaffold/tailwind.config.ts +0 -57
- package/dist/scaffold/tsconfig.json +0 -20
|
@@ -1,218 +0,0 @@
|
|
|
1
|
-
# Plan Mode Instructions
|
|
2
|
-
|
|
3
|
-
## Overview
|
|
4
|
-
|
|
5
|
-
Plan Mode is a structured approach to problem-solving that emphasizes **clarity, alignment, and decision-completeness** before implementation.
|
|
6
|
-
|
|
7
|
-
When in Plan Mode, you must follow the **3-phase workflow**:
|
|
8
|
-
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
## Phase 1: Grounding (Understanding)
|
|
12
|
-
|
|
13
|
-
**Goal:** Demonstrate deep understanding of the problem before proposing solutions.
|
|
14
|
-
|
|
15
|
-
**Actions:**
|
|
16
|
-
- Read relevant files to understand context
|
|
17
|
-
- Identify the root cause, not just symptoms
|
|
18
|
-
- Map out the codebase structure affected
|
|
19
|
-
- Ask clarifying questions if information is missing
|
|
20
|
-
|
|
21
|
-
**Output format:**
|
|
22
|
-
```
|
|
23
|
-
<proposed_plan>
|
|
24
|
-
## Understanding
|
|
25
|
-
|
|
26
|
-
### What I Found
|
|
27
|
-
- [Key findings from investigation]
|
|
28
|
-
- [Root cause analysis]
|
|
29
|
-
- [Files and lines involved]
|
|
30
|
-
|
|
31
|
-
### Context
|
|
32
|
-
- [Relevant code patterns]
|
|
33
|
-
- [Dependencies and side effects]
|
|
34
|
-
</proposed_plan>
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
---
|
|
38
|
-
|
|
39
|
-
## Phase 2: Intent (Proposal)
|
|
40
|
-
|
|
41
|
-
**Goal:** Present a clear, actionable plan for user approval.
|
|
42
|
-
|
|
43
|
-
**Actions:**
|
|
44
|
-
- Propose specific changes with file paths and line numbers
|
|
45
|
-
- Explain the "why" behind each decision
|
|
46
|
-
- Consider alternatives and trade-offs
|
|
47
|
-
- Make the plan "decision complete" (user can approve without asking follow-ups)
|
|
48
|
-
|
|
49
|
-
**Output format:**
|
|
50
|
-
```
|
|
51
|
-
<proposed_plan>
|
|
52
|
-
## Proposed Plan
|
|
53
|
-
|
|
54
|
-
### Objective
|
|
55
|
-
[Clear statement of what we're fixing/building]
|
|
56
|
-
|
|
57
|
-
### Approach
|
|
58
|
-
1. [Step 1 with specific files/lines]
|
|
59
|
-
2. [Step 2 with specific files/lines]
|
|
60
|
-
3. [Step 3...]
|
|
61
|
-
|
|
62
|
-
### Changes
|
|
63
|
-
- **File: `src/path/to/file.ts`**
|
|
64
|
-
- Line 42: Change X to Y because...
|
|
65
|
-
- Add function `helper()` at line 50 to...
|
|
66
|
-
|
|
67
|
-
### Alternatives Considered
|
|
68
|
-
- Alternative A: [why not chosen]
|
|
69
|
-
- Alternative B: [why not chosen]
|
|
70
|
-
|
|
71
|
-
### Risks & Mitigations
|
|
72
|
-
- [Potential issue] → [mitigation strategy]
|
|
73
|
-
|
|
74
|
-
### Success Criteria
|
|
75
|
-
- [How we'll know this is working]
|
|
76
|
-
- [Tests to run]
|
|
77
|
-
</proposed_plan>
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
---
|
|
81
|
-
|
|
82
|
-
## Phase 3: Implementation (Execution)
|
|
83
|
-
|
|
84
|
-
**Goal:** Execute the approved plan with precision.
|
|
85
|
-
|
|
86
|
-
**Actions:**
|
|
87
|
-
- Follow the approved plan exactly
|
|
88
|
-
- Use `enter_plan_mode` before making changes
|
|
89
|
-
- Make surgical, targeted edits
|
|
90
|
-
- Run tests after each change
|
|
91
|
-
- Use `exit_plan_mode` when complete
|
|
92
|
-
|
|
93
|
-
**Important:**
|
|
94
|
-
- Do NOT deviate from the approved plan without user consent
|
|
95
|
-
- If you discover new issues, pause and propose an updated plan
|
|
96
|
-
- Commit changes with clear, descriptive messages
|
|
97
|
-
|
|
98
|
-
---
|
|
99
|
-
|
|
100
|
-
## Plan Mode Rules
|
|
101
|
-
|
|
102
|
-
### DO:
|
|
103
|
-
✅ Use `<proposed_plan>` tags for all plans
|
|
104
|
-
✅ Make plans "decision complete" (no follow-up questions needed)
|
|
105
|
-
✅ Include specific file paths and line numbers
|
|
106
|
-
✅ Explain reasoning behind each decision
|
|
107
|
-
✅ Consider alternatives and trade-offs
|
|
108
|
-
✅ Use `enter_plan_mode` before making changes
|
|
109
|
-
✅ Run tests and verify changes work
|
|
110
|
-
|
|
111
|
-
### DON'T:
|
|
112
|
-
❌ Make changes without a proposed plan
|
|
113
|
-
❌ Propose vague or incomplete plans
|
|
114
|
-
❌ Skip the grounding phase (understand first!)
|
|
115
|
-
❌ Deviate from approved plan without consent
|
|
116
|
-
❌ Make multiple unrelated changes in one plan
|
|
117
|
-
❌ Forget to run tests after implementation
|
|
118
|
-
|
|
119
|
-
---
|
|
120
|
-
|
|
121
|
-
## When to Use Plan Mode
|
|
122
|
-
|
|
123
|
-
**Use Plan Mode when:**
|
|
124
|
-
- Fixing bugs (especially complex ones)
|
|
125
|
-
- Adding new features
|
|
126
|
-
- Refactoring code
|
|
127
|
-
- Making architectural changes
|
|
128
|
-
- Any change that affects multiple files
|
|
129
|
-
|
|
130
|
-
**Skip Plan Mode for:**
|
|
131
|
-
- Simple, one-line fixes
|
|
132
|
-
- Reading files to gather information
|
|
133
|
-
- Quick exploratory tasks
|
|
134
|
-
- User explicitly asks to "just fix it"
|
|
135
|
-
|
|
136
|
-
---
|
|
137
|
-
|
|
138
|
-
## Plan Mode Workflow Summary
|
|
139
|
-
|
|
140
|
-
1. **Investigate** → Read files, understand the problem
|
|
141
|
-
2. **Propose** → Create `<proposed_plan>` with clear steps
|
|
142
|
-
3. **Wait** → Let user review and approve
|
|
143
|
-
4. **Activate** → Call `enter_plan_mode` when approved
|
|
144
|
-
5. **Implement** → Make the changes exactly as proposed
|
|
145
|
-
6. **Verify** → Run tests, confirm success
|
|
146
|
-
7. **Complete** → Call `exit_plan_mode` and report results
|
|
147
|
-
|
|
148
|
-
---
|
|
149
|
-
|
|
150
|
-
## Example Plan
|
|
151
|
-
|
|
152
|
-
```
|
|
153
|
-
<proposed_plan>
|
|
154
|
-
## Understanding
|
|
155
|
-
|
|
156
|
-
### What I Found
|
|
157
|
-
- Null pointer in `src/auth/validate.ts:42` when `Session.expired` is true
|
|
158
|
-
- The `user` field is undefined but code tries to access `user.id`
|
|
159
|
-
- This happens because token cache isn't cleared on expiry
|
|
160
|
-
|
|
161
|
-
### Context
|
|
162
|
-
- `validateToken()` returns cached token even when expired
|
|
163
|
-
- `getSession()` doesn't check if user exists before accessing properties
|
|
164
|
-
|
|
165
|
-
## Proposed Plan
|
|
166
|
-
|
|
167
|
-
### Objective
|
|
168
|
-
Fix null pointer exception when session expires but token is cached
|
|
169
|
-
|
|
170
|
-
### Approach
|
|
171
|
-
1. Add null check in `validate.ts:42` before accessing `user.id`
|
|
172
|
-
2. Clear token cache when session expires
|
|
173
|
-
3. Add test case for expired session with cached token
|
|
174
|
-
|
|
175
|
-
### Changes
|
|
176
|
-
- **File: `src/auth/validate.ts`**
|
|
177
|
-
- Line 42: Add `if (!user) return { valid: false, error: 'Session expired' };`
|
|
178
|
-
- Line 58: Add cache invalidation when `Session.expired === true`
|
|
179
|
-
|
|
180
|
-
### Alternatives Considered
|
|
181
|
-
- Alternative: Always refresh token on expiry → Too aggressive, impacts performance
|
|
182
|
-
- Alternative: Remove caching entirely → Loses benefit of caching valid tokens
|
|
183
|
-
|
|
184
|
-
### Risks & Mitigations
|
|
185
|
-
- Risk: Breaking existing valid sessions → Mitigation: Add comprehensive tests
|
|
186
|
-
- Risk: Performance impact from cache invalidation → Mitigation: Only invalidate on confirmed expiry
|
|
187
|
-
|
|
188
|
-
### Success Criteria
|
|
189
|
-
- No null pointer on expired session
|
|
190
|
-
- Valid sessions still cached and fast
|
|
191
|
-
- Test coverage for edge case added
|
|
192
|
-
</proposed_plan>
|
|
193
|
-
```
|
|
194
|
-
|
|
195
|
-
---
|
|
196
|
-
|
|
197
|
-
## Tool Usage in Plan Mode
|
|
198
|
-
|
|
199
|
-
When `enter_plan_mode` is active:
|
|
200
|
-
- All write/execute tools require explicit confirmation
|
|
201
|
-
- This ensures you review each change before it happens
|
|
202
|
-
- Use this as a safety check, not a barrier
|
|
203
|
-
|
|
204
|
-
Tools that require confirmation in Plan Mode:
|
|
205
|
-
- `edit_tool`
|
|
206
|
-
- `file_write`
|
|
207
|
-
- `shell_command`
|
|
208
|
-
- `spawn_agent`
|
|
209
|
-
|
|
210
|
-
---
|
|
211
|
-
|
|
212
|
-
## Final Notes
|
|
213
|
-
|
|
214
|
-
**Remember:** A good plan is specific, actionable, and decision-complete.
|
|
215
|
-
The user should be able to approve your plan without asking "what about X?" or "why this approach?"
|
|
216
|
-
|
|
217
|
-
If you're unsure, **ask questions first** before proposing the plan.
|
|
218
|
-
Better to spend 2 minutes clarifying than 20 minutes fixing the wrong thing.
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: factorai-sh
|
|
3
|
-
description: >
|
|
4
|
-
Use for FactorAI.sh / Severino Next.js hosting in sandbox: scaffold, first deploy,
|
|
5
|
-
edit live apps, rebuild (Vercel-like). Triggers: "deploy next", "factorai.sh",
|
|
6
|
-
"criar app nextjs", "portfolio online", "rebuild", "atualizar app deployada",
|
|
7
|
-
"apply_app_changes", "redeploy", "factor-sh-url-app".
|
|
8
|
-
license: Proprietary
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
# FactorAI.sh — Next.js deploy & incremental rebuild
|
|
12
|
-
|
|
13
|
-
## Prerequisites
|
|
14
|
-
|
|
15
|
-
- Sandbox: `BLUMA_SANDBOX=true`
|
|
16
|
-
- `FACTORAI_BASE_URL` and `SEVERINO_URL` are set in your environment — tools call those bases automatically
|
|
17
|
-
- Do **not** invent API hosts or guess prod vs dev; use env + `factorai.sh.json` only
|
|
18
|
-
- Optional: `FACTORAI_API_KEY` / `SEVERINO_API_KEY` when the server requires auth
|
|
19
|
-
|
|
20
|
-
## Manifest
|
|
21
|
-
|
|
22
|
-
Always read `factorai.sh.json` in the project root before editing a deployed app:
|
|
23
|
-
|
|
24
|
-
- `appContext.appId` — UUID for all FactorAI API tools
|
|
25
|
-
- `appContext.appUrl` — path or URL for the live app → use for `factor-sh-url-app` (resolve to absolute URL via manifest + `SEVERINO_URL` when path-only)
|
|
26
|
-
|
|
27
|
-
## Session scope
|
|
28
|
-
|
|
29
|
-
- Each `session_id` has its own sandbox workspace. Manifest and project files exist **only** there.
|
|
30
|
-
- Do not use `appId` from another session. If `factorai.sh.json` is missing in cwd, create/deploy the app in **this** session first.
|
|
31
|
-
|
|
32
|
-
## Flow A — New app
|
|
33
|
-
|
|
34
|
-
```text
|
|
35
|
-
1. factorai.sh.create_next_app({ name: "my-app" })
|
|
36
|
-
→ Read tool result `agentGuide` (or ./my-app/DESIGN.md): tokens, @/components/ui/* inventory, UI do/don'ts
|
|
37
|
-
2. edit_tool / file_write under ./my-app/ using shadcn components + semantic Tailwind (bg-background, etc.)
|
|
38
|
-
3. Avoid npm run build before deploy (.next inflates ZIP); optional npx tsc --noEmit
|
|
39
|
-
4. factorai.sh.deploy_app({ projectDir: "./my-app", name: "my-app" })
|
|
40
|
-
5. factorai.sh.get_app_status({ appId, wait: true }) until ready or failed (see Polling)
|
|
41
|
-
6. message(result) with factor-sh-url-app from manifest after ready
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
## Flow B — App already online in this session (like Vercel)
|
|
45
|
-
|
|
46
|
-
```text
|
|
47
|
-
1. Read factorai.sh.json in cwd → appId
|
|
48
|
-
2. edit_tool / file_write locally, then read_file_lines the FULL changed file(s)
|
|
49
|
-
3. factorai.sh.apply_app_changes({
|
|
50
|
-
appId: "<uuid from this session manifest>",
|
|
51
|
-
files: [
|
|
52
|
-
{ path: "app/page.tsx", content: "<ENTIRE file contents after edit>" },
|
|
53
|
-
],
|
|
54
|
-
deploy: true,
|
|
55
|
-
})
|
|
56
|
-
4. get_app_status({ appId, wait: true }) until ready or failed
|
|
57
|
-
5. message(result) with factor-sh-url-app from manifest after ready
|
|
58
|
-
```
|
|
59
|
-
|
|
60
|
-
**Wrong patterns:**
|
|
61
|
-
|
|
62
|
-
- `files[].content` with only a footer/section snippet → server replaces whole file → broken page
|
|
63
|
-
- `file_write` only without `apply_app_changes` → running app unchanged
|
|
64
|
-
- `deploy_app` again for a one-line JSX change → slow, wasteful
|
|
65
|
-
- ZIP with `node_modules` → fails or exceeds size limit
|
|
66
|
-
- Hardcoding deploy/API hosts instead of using configured env
|
|
67
|
-
|
|
68
|
-
## Polling checklist
|
|
69
|
-
|
|
70
|
-
1. Prefer `factorai.sh.get_app_status({ appId, wait: true })` — blocks until `ready` or `failed`
|
|
71
|
-
2. On `failed`: read `data.typescriptErrors`, `data.buildLogTail`, `data.summary` — fix code, retry apply/deploy
|
|
72
|
-
3. Do not report live URL until `data.success === true` and `data.status === "ready"`
|
|
73
|
-
4. Typical rebuild: 30–90 seconds
|
|
74
|
-
|
|
75
|
-
## Tool reference
|
|
76
|
-
|
|
77
|
-
| Tool | Purpose |
|
|
78
|
-
|------|---------|
|
|
79
|
-
| `factorai.sh.create_next_app` | Scaffold Next 14 + full shadcn/ui; returns `agentGuide` + `DESIGN.md`; default = polished dark landing |
|
|
80
|
-
| `factorai.sh.deploy_app` | First deploy: ZIP source → deploy API on `SEVERINO_URL` |
|
|
81
|
-
| `factorai.sh.apply_app_changes` | Patch files on server + `next build` + restart |
|
|
82
|
-
| `factorai.sh.get_app_status` | Status + contract |
|
|
83
|
-
| `factorai.sh.redeploy_app` | Rebuild without uploading new file contents |
|
|
84
|
-
|
|
85
|
-
## Troubleshooting
|
|
86
|
-
|
|
87
|
-
| Symptom | Action |
|
|
88
|
-
|---------|--------|
|
|
89
|
-
| `Couldn't find app directory` | Re-run `create_next_app` — scaffold must include `app/` |
|
|
90
|
-
| `Cannot find name 'Slot'` | Broken shadcn template — use fixed scaffold or simplify `components/ui/button.tsx` |
|
|
91
|
-
| ZIP too large | Ensure `node_modules` not in ZIP; `deploy_app` excludes it |
|
|
92
|
-
| `ready` but 503/JSON error | Keep polling; rebuild still running |
|
|
93
|
-
| curl deploy fails on headers | Use tools, not manual curl |
|
|
94
|
-
|
|
95
|
-
## End of task
|
|
96
|
-
|
|
97
|
-
- `message({ message_type: "result", content: "...", "factor-sh-url-app": "<absolute live url from manifest>" })` — **required** for Severino; auto-filled from `factorai.sh.json` if omitted
|
|
98
|
-
- `attachments[]` — only for files under `.bluma/artifacts/`, not the app URL
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
BluMa — Base Language Unit · Model Agent
|
|
2
|
-
Proprietary License
|
|
3
|
-
|
|
4
|
-
Copyright (c) 2024-2026 BluMa Contributors
|
|
5
|
-
|
|
6
|
-
This skill is part of the BluMa CLI distribution.
|
|
7
|
-
It is provided as a bundled native skill and may not be
|
|
8
|
-
redistributed, modified, or used outside of the BluMa agent
|
|
9
|
-
framework without prior written permission.
|
|
10
|
-
|
|
11
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
12
|
-
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
|
13
|
-
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
14
|
-
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
|
15
|
-
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
16
|
-
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
17
|
-
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
18
|
-
OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -1,300 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: git-commit
|
|
3
|
-
description: >
|
|
4
|
-
Use this skill whenever the user asks to commit code, stage changes, write
|
|
5
|
-
a commit message, or finalize work. Triggers: "commit", "commit my changes",
|
|
6
|
-
"stage and commit", "save my work", "git commit", "write a commit message",
|
|
7
|
-
"commit this", "amend commit", or any request to record changes in Git
|
|
8
|
-
history. Enforces atomic commits per feature or concern: stage with explicit
|
|
9
|
-
paths or git add -p; never git add ., git add -A, or git add --all. Do NOT
|
|
10
|
-
use for pull requests — use git-pr instead.
|
|
11
|
-
license: Proprietary. LICENSE.txt has complete terms
|
|
12
|
-
---
|
|
13
|
-
|
|
14
|
-
# Git Commit — Professional Workflow
|
|
15
|
-
|
|
16
|
-
## Golden Rule
|
|
17
|
-
|
|
18
|
-
> Every commit tells a story. The subject says WHAT, the body says WHY,
|
|
19
|
-
> and the diff shows HOW. Never repeat the diff in the message.
|
|
20
|
-
|
|
21
|
-
## Staging Discipline (Non-Negotiable)
|
|
22
|
-
|
|
23
|
-
BluMa must behave like a senior engineer committing: **one commit = one
|
|
24
|
-
coherent unit of work** (typically one feature, one fix, or one concern).
|
|
25
|
-
That requires **surgical staging**, not “stage the whole tree”.
|
|
26
|
-
|
|
27
|
-
**FORBIDDEN — never run or suggest as the default workflow:**
|
|
28
|
-
|
|
29
|
-
- `git add .`
|
|
30
|
-
- `git add -A` / `git add --all`
|
|
31
|
-
- Any variant that stages every change in the repo without naming paths
|
|
32
|
-
|
|
33
|
-
Those commands mix unrelated edits, hide what is being recorded, and
|
|
34
|
-
break atomic history. If the user insists on a blanket add, explain the
|
|
35
|
-
risk once, then still prefer explicit paths or `git add -p`.
|
|
36
|
-
|
|
37
|
-
**REQUIRED — stage with intent:**
|
|
38
|
-
|
|
39
|
-
- `git add <path> [<path> ...]` for whole files that belong to *this*
|
|
40
|
-
commit only
|
|
41
|
-
- `git add -p` / `git add --patch` when only part of a file belongs to
|
|
42
|
-
this commit (split hunks across commits if needed)
|
|
43
|
-
- `git restore --staged <path>` to unstage mistakes before committing
|
|
44
|
-
|
|
45
|
-
When several features or concerns are dirty, **commit them in separate
|
|
46
|
-
commits**, each with its own explicit `git add` of the relevant paths —
|
|
47
|
-
never one giant commit because “it was all green in `git status`”.
|
|
48
|
-
|
|
49
|
-
## Step 1 — Inspect the Working Tree
|
|
50
|
-
|
|
51
|
-
Before committing anything, understand the current state:
|
|
52
|
-
|
|
53
|
-
```bash
|
|
54
|
-
git status --short
|
|
55
|
-
git diff --stat
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
Identify which files belong to which logical change. If there are
|
|
59
|
-
unrelated changes, they MUST go into separate commits (see Atomic
|
|
60
|
-
Commits below).
|
|
61
|
-
|
|
62
|
-
## Step 2 — Stage with Intent
|
|
63
|
-
|
|
64
|
-
Stage only the files (or hunks) that belong to **one** logical change —
|
|
65
|
-
aligned with **one** feature, fix, or refactor slice you could review in
|
|
66
|
-
isolation:
|
|
67
|
-
|
|
68
|
-
```bash
|
|
69
|
-
git add path/to/file.ts path/to/file.test.ts
|
|
70
|
-
# or, for part of a file:
|
|
71
|
-
git add -p path/to/file.ts
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
Do **not** use repository-wide adds (see Staging Discipline above).
|
|
75
|
-
|
|
76
|
-
Review what is staged:
|
|
77
|
-
|
|
78
|
-
```bash
|
|
79
|
-
git diff --staged
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
Read the diff carefully. You need it to write an accurate message.
|
|
83
|
-
|
|
84
|
-
## Step 3 — Determine the Commit Type
|
|
85
|
-
|
|
86
|
-
| Prefix | Meaning |
|
|
87
|
-
|------------|--------------------------------------------------|
|
|
88
|
-
| `feat` | New feature or user-facing capability |
|
|
89
|
-
| `fix` | Bug fix |
|
|
90
|
-
| `refactor` | Code restructuring, no behavior change |
|
|
91
|
-
| `docs` | Documentation only |
|
|
92
|
-
| `test` | Adding or updating tests |
|
|
93
|
-
| `perf` | Performance improvement |
|
|
94
|
-
| `style` | Formatting, whitespace, linting (no logic) |
|
|
95
|
-
| `chore` | Build, CI, dependencies, tooling |
|
|
96
|
-
| `security` | Security fix or hardening |
|
|
97
|
-
| `revert` | Reverting a previous commit |
|
|
98
|
-
|
|
99
|
-
## Step 4 — Write the Commit Message
|
|
100
|
-
|
|
101
|
-
### Format
|
|
102
|
-
|
|
103
|
-
```
|
|
104
|
-
<type>(<scope>): <subject>
|
|
105
|
-
|
|
106
|
-
<body>
|
|
107
|
-
|
|
108
|
-
<footer>
|
|
109
|
-
|
|
110
|
-
Generated-by: BluMa — Base Language Unit · Model Agent
|
|
111
|
-
```
|
|
112
|
-
|
|
113
|
-
### Subject Line Rules
|
|
114
|
-
|
|
115
|
-
- Imperative mood: "add", "fix", "remove" (not "added", "fixes", "removed")
|
|
116
|
-
- Lowercase first letter after the colon
|
|
117
|
-
- No period at the end
|
|
118
|
-
- Maximum 72 characters
|
|
119
|
-
- Include scope when the change targets a specific module
|
|
120
|
-
|
|
121
|
-
Good examples:
|
|
122
|
-
```
|
|
123
|
-
feat(auth): add JWT refresh token rotation
|
|
124
|
-
fix(parser): handle empty input without panic
|
|
125
|
-
refactor(db): extract connection pooling into module
|
|
126
|
-
docs(readme): add installation instructions for ARM64
|
|
127
|
-
chore(deps): bump openai SDK to v4.50.0
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
Bad examples:
|
|
131
|
-
```
|
|
132
|
-
Updated stuff # vague, no type, no scope
|
|
133
|
-
fix: Fixed the bug in auth module. # past tense, period, scope missing
|
|
134
|
-
feat(auth): Add JWT refresh token rotation for users to be able to
|
|
135
|
-
refresh their tokens automatically # too long, wraps
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
### Body Rules
|
|
139
|
-
|
|
140
|
-
- Leave ONE blank line between subject and body
|
|
141
|
-
- Explain WHY the change was needed, not WHAT changed
|
|
142
|
-
- Wrap at 72 characters
|
|
143
|
-
- Use bullet points for multiple reasons or details
|
|
144
|
-
- Reference design decisions or trade-offs if relevant
|
|
145
|
-
|
|
146
|
-
### Footer Rules
|
|
147
|
-
|
|
148
|
-
- Reference issues: `Closes #123`, `Refs #456`, `Fixes #789`
|
|
149
|
-
- Note breaking changes: `BREAKING CHANGE: <description>`
|
|
150
|
-
- Co-authors: `Co-authored-by: Name <email>`
|
|
151
|
-
|
|
152
|
-
### Watermark (MANDATORY)
|
|
153
|
-
|
|
154
|
-
The last line of every commit message MUST be:
|
|
155
|
-
|
|
156
|
-
```
|
|
157
|
-
Generated-by: BluMa — Base Language Unit · Model Agent
|
|
158
|
-
```
|
|
159
|
-
|
|
160
|
-
This provides auditability. No exceptions.
|
|
161
|
-
|
|
162
|
-
## Step 5 — Execute the Commit
|
|
163
|
-
|
|
164
|
-
Use heredoc for clean multi-line messages:
|
|
165
|
-
|
|
166
|
-
```bash
|
|
167
|
-
git commit -m "$(cat <<'EOF'
|
|
168
|
-
feat(skills): add git-commit skill for professional workflows
|
|
169
|
-
|
|
170
|
-
Introduce a dedicated skill that guides the agent through
|
|
171
|
-
Conventional Commits with proper subject, body, and footer
|
|
172
|
-
formatting. Ensures every commit carries the BluMa watermark
|
|
173
|
-
trailer for auditability.
|
|
174
|
-
|
|
175
|
-
- Atomic commit principles enforced
|
|
176
|
-
- Subject line validation (72 chars, imperative mood)
|
|
177
|
-
- Mandatory BluMa watermark trailer
|
|
178
|
-
|
|
179
|
-
Closes #55
|
|
180
|
-
|
|
181
|
-
Generated-by: BluMa — Base Language Unit · Model Agent
|
|
182
|
-
EOF
|
|
183
|
-
)"
|
|
184
|
-
```
|
|
185
|
-
|
|
186
|
-
For simple single-line commits (rare, only for truly trivial changes):
|
|
187
|
-
|
|
188
|
-
```bash
|
|
189
|
-
git commit -m "chore(deps): bump typescript to v5.5.0
|
|
190
|
-
|
|
191
|
-
Generated-by: BluMa — Base Language Unit · Model Agent"
|
|
192
|
-
```
|
|
193
|
-
|
|
194
|
-
## Step 6 — Verify
|
|
195
|
-
|
|
196
|
-
```bash
|
|
197
|
-
git log -1 --format=fuller
|
|
198
|
-
```
|
|
199
|
-
|
|
200
|
-
Confirm the message is well-formed and the watermark is present.
|
|
201
|
-
|
|
202
|
-
## Atomic Commits
|
|
203
|
-
|
|
204
|
-
Each commit MUST represent exactly **one** logical change — the same
|
|
205
|
-
bar a senior would use before pushing: a reviewer can understand the
|
|
206
|
-
**why** from the message and the **what** from the diff without unrelated
|
|
207
|
-
noise.
|
|
208
|
-
|
|
209
|
-
Organize history **by feature or concern**, not by “everything I touched
|
|
210
|
-
today”:
|
|
211
|
-
|
|
212
|
-
| Scenario | Commits |
|
|
213
|
-
|----------|---------|
|
|
214
|
-
| Added a feature + updated docs | 2 commits: `feat(...)` + `docs(...)` |
|
|
215
|
-
| Fixed a bug + added a test for it | 1 commit: `fix(...)` (test is part of the fix) |
|
|
216
|
-
| Renamed a variable across 10 files | 1 commit: `refactor(...)` |
|
|
217
|
-
| Fixed 2 unrelated bugs | 2 commits: `fix(...)` + `fix(...)` |
|
|
218
|
-
| New feature + refactored old code to support it | 2 commits: `refactor(...)` first, then `feat(...)` |
|
|
219
|
-
|
|
220
|
-
When in doubt: if you can describe the commit with "X and Y", it should
|
|
221
|
-
probably be two commits — and each of those commits gets its **own**
|
|
222
|
-
explicit `git add` of only the paths for X or Y.
|
|
223
|
-
|
|
224
|
-
## Handling Special Cases
|
|
225
|
-
|
|
226
|
-
### Amending the Last Commit
|
|
227
|
-
|
|
228
|
-
Only amend if the commit has NOT been pushed:
|
|
229
|
-
|
|
230
|
-
```bash
|
|
231
|
-
git add <forgotten-file>
|
|
232
|
-
git commit --amend --no-edit
|
|
233
|
-
```
|
|
234
|
-
|
|
235
|
-
To change the message:
|
|
236
|
-
|
|
237
|
-
```bash
|
|
238
|
-
git commit --amend -m "$(cat <<'EOF'
|
|
239
|
-
<corrected message>
|
|
240
|
-
|
|
241
|
-
Generated-by: BluMa — Base Language Unit · Model Agent
|
|
242
|
-
EOF
|
|
243
|
-
)"
|
|
244
|
-
```
|
|
245
|
-
|
|
246
|
-
### Empty Commits (for CI triggers)
|
|
247
|
-
|
|
248
|
-
```bash
|
|
249
|
-
git commit --allow-empty -m "$(cat <<'EOF'
|
|
250
|
-
chore(ci): trigger pipeline rebuild
|
|
251
|
-
|
|
252
|
-
Generated-by: BluMa — Base Language Unit · Model Agent
|
|
253
|
-
EOF
|
|
254
|
-
)"
|
|
255
|
-
```
|
|
256
|
-
|
|
257
|
-
### Reverting a Commit
|
|
258
|
-
|
|
259
|
-
```bash
|
|
260
|
-
git revert <hash> --no-edit
|
|
261
|
-
```
|
|
262
|
-
|
|
263
|
-
Then amend to add context and watermark:
|
|
264
|
-
|
|
265
|
-
```bash
|
|
266
|
-
git commit --amend -m "$(cat <<'EOF'
|
|
267
|
-
revert(auth): undo token expiry change
|
|
268
|
-
|
|
269
|
-
Reverts commit <hash>. The 30-minute expiry caused session drops
|
|
270
|
-
for users on slow connections. Reverting until a proper sliding
|
|
271
|
-
window solution is implemented.
|
|
272
|
-
|
|
273
|
-
Refs #130
|
|
274
|
-
|
|
275
|
-
Generated-by: BluMa — Base Language Unit · Model Agent
|
|
276
|
-
EOF
|
|
277
|
-
)"
|
|
278
|
-
```
|
|
279
|
-
|
|
280
|
-
## Quality Checklist
|
|
281
|
-
|
|
282
|
-
Before finalizing any commit, verify:
|
|
283
|
-
|
|
284
|
-
1. Type prefix is correct for the change
|
|
285
|
-
2. Scope accurately reflects the affected module
|
|
286
|
-
3. Subject is imperative, lowercase, under 72 chars
|
|
287
|
-
4. Body explains WHY (not WHAT)
|
|
288
|
-
5. Footer references relevant issues
|
|
289
|
-
6. Watermark `Generated-by: BluMa` is the last line
|
|
290
|
-
7. Only related changes are included (atomic); staging used explicit
|
|
291
|
-
paths or `-p`, never `git add .` / `git add -A`
|
|
292
|
-
8. No secrets, credentials, or .env files are staged
|
|
293
|
-
|
|
294
|
-
## Available References
|
|
295
|
-
|
|
296
|
-
- REFERENCE.md: Advanced patterns (signed commits, co-authors, commit hooks, monorepo conventions, interactive rebase guidance)
|
|
297
|
-
|
|
298
|
-
## Available Scripts
|
|
299
|
-
|
|
300
|
-
- validate_commit_msg.py: Validates a commit message string against Conventional Commits rules and BluMa watermark presence
|