@letta-ai/letta-code 0.21.16 → 0.21.17
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/letta.js +510 -337
- package/package.json +1 -1
- package/skills/working-in-parallel/SKILL.md +25 -10
package/package.json
CHANGED
|
@@ -11,6 +11,17 @@ Git worktrees let you check out multiple branches into separate directories. Eac
|
|
|
11
11
|
|
|
12
12
|
Learn more: [Git worktree documentation](https://git-scm.com/docs/git-worktree)
|
|
13
13
|
|
|
14
|
+
## IMPORTANT: Worktree Location
|
|
15
|
+
|
|
16
|
+
**All worktrees MUST be created under `.letta/worktrees/` in the repo root.** This keeps worktrees organized, gitignored, and out of the user's project directory.
|
|
17
|
+
|
|
18
|
+
Before creating the first worktree, ensure `.letta/worktrees` is in the repo's `.gitignore`:
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
# Add to .gitignore if not already present
|
|
22
|
+
grep -q '.letta/worktrees' .gitignore 2>/dev/null || echo '.letta/worktrees' >> .gitignore
|
|
23
|
+
```
|
|
24
|
+
|
|
14
25
|
## IMPORTANT: Check Project Setup First
|
|
15
26
|
|
|
16
27
|
Before running ANY commands in a new worktree, check the project's setup instructions:
|
|
@@ -24,11 +35,14 @@ Don't assume `npm` vs `bun` vs `pnpm` - **check the project first!**
|
|
|
24
35
|
## Quick Start
|
|
25
36
|
|
|
26
37
|
```bash
|
|
27
|
-
#
|
|
28
|
-
|
|
38
|
+
# Ensure .letta/worktrees is gitignored
|
|
39
|
+
grep -q '.letta/worktrees' .gitignore 2>/dev/null || echo '.letta/worktrees' >> .gitignore
|
|
40
|
+
|
|
41
|
+
# Create worktree with new branch (from repo root)
|
|
42
|
+
git worktree add -b fix/my-feature .letta/worktrees/my-feature main
|
|
29
43
|
|
|
30
44
|
# Work in the worktree
|
|
31
|
-
cd
|
|
45
|
+
cd .letta/worktrees/my-feature
|
|
32
46
|
|
|
33
47
|
# CHECK PROJECT SETUP FIRST - then install dependencies
|
|
34
48
|
# Read README.md or check project memory block for correct command
|
|
@@ -40,17 +54,17 @@ git commit -m "fix: description"
|
|
|
40
54
|
git push -u origin fix/my-feature
|
|
41
55
|
gh pr create --title "Fix: description" --body "## Summary..."
|
|
42
56
|
|
|
43
|
-
# Clean up when done (from
|
|
44
|
-
git worktree remove
|
|
57
|
+
# Clean up when done (from repo root)
|
|
58
|
+
git worktree remove .letta/worktrees/my-feature
|
|
45
59
|
```
|
|
46
60
|
|
|
47
61
|
## Key Commands
|
|
48
62
|
|
|
49
63
|
```bash
|
|
50
|
-
git worktree add -b <branch>
|
|
51
|
-
git worktree add
|
|
52
|
-
git worktree list
|
|
53
|
-
git worktree remove
|
|
64
|
+
git worktree add -b <branch> .letta/worktrees/<name> main # Create with new branch
|
|
65
|
+
git worktree add .letta/worktrees/<name> <existing-branch> # Use existing branch
|
|
66
|
+
git worktree list # Show all worktrees
|
|
67
|
+
git worktree remove .letta/worktrees/<name> # Remove worktree
|
|
54
68
|
```
|
|
55
69
|
|
|
56
70
|
## When to Use
|
|
@@ -65,8 +79,9 @@ Worktrees share `.git`, but pre-commit hooks may need initialization depending o
|
|
|
65
79
|
|
|
66
80
|
## Tips
|
|
67
81
|
|
|
82
|
+
- **Always use `.letta/worktrees/`** - never create worktrees outside this directory
|
|
68
83
|
- **Check project setup docs before installing** - README, claude.md, project memory block
|
|
69
|
-
- Name
|
|
84
|
+
- Name worktrees clearly: `.letta/worktrees/feature-auth`, `.letta/worktrees/bugfix-123`
|
|
70
85
|
- Install dependencies using the project's package manager (check first!)
|
|
71
86
|
- Push changes before removing worktrees
|
|
72
87
|
|