Repository navigation
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·73 lines (55 loc) · 2.9 KB
/
Copy pathinstall.sh
File metadata and controls
executable file
·73 lines (55 loc) · 2.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#!/bin/bash
set -e
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
# Prefer `pi install` if pi is available
if command -v pi &>/dev/null; then
pi install "$SCRIPT_DIR"
cat <<EOF
────────────────────────────────────────────────────────────
✓ Installed atomic-pi via pi install
────────────────────────────────────────────────────────────
What was installed:
pi handles placement automatically from this checkout:
${SCRIPT_DIR}
• Extension extensions/atomic-hooks.ts (session lifecycle, turn recording)
• Skills atomic-vault, atomic-vcs, code-intelligence
Manual steps to finish:
1. Ensure your project is an Atomic repo (one-time):
cd /path/to/your/project && atomic init
2. Restart pi if it's already running so it picks up the extension.
Verify:
• Run 'pi' in an Atomic project — the Atomic agent activates automatically.
────────────────────────────────────────────────────────────
EOF
exit 0
fi
# Fallback: symlink into ~/.pi/agent/ directly
TARGET="$HOME/.pi/agent"
mkdir -p "$TARGET/extensions" "$TARGET/skills"
ln -sf "$SCRIPT_DIR/extensions/atomic-hooks.ts" "$TARGET/extensions/atomic-hooks.ts"
# Skills — explicit, no globs
for name in atomic-vault atomic-vcs code-intelligence; do
mkdir -p "$TARGET/skills/$name"
ln -sf "$SCRIPT_DIR/skills/$name/SKILL.md" "$TARGET/skills/$name/SKILL.md"
done
cat <<EOF
────────────────────────────────────────────────────────────
✓ Installed atomic-pi
────────────────────────────────────────────────────────────
What was installed:
• Extension → ${TARGET}/extensions/atomic-hooks.ts
• Skills → ${TARGET}/skills/atomic-vault/SKILL.md
→ ${TARGET}/skills/atomic-vcs/SKILL.md
→ ${TARGET}/skills/code-intelligence/SKILL.md
Symlinks point back into this checkout:
${SCRIPT_DIR}
Keep this directory in place; moving or deleting it breaks the links.
Manual steps to finish:
1. Restart pi if it's already running so it picks up the extension.
2. Ensure your project is an Atomic repo (one-time):
cd /path/to/your/project && atomic init
Verify:
• Skills: ls ${TARGET}/skills/
(Preferred method: pi install ${SCRIPT_DIR})
────────────────────────────────────────────────────────────
EOF