-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·56 lines (47 loc) · 1.2 KB
/
install.sh
File metadata and controls
executable file
·56 lines (47 loc) · 1.2 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
#!/usr/bin/env bash
set -euo pipefail
# Install codingskills into the current project.
# Copies skills/ to .agents/skills/ and symlinks .claude/skills/ for Claude Code.
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
AGENTS_DIR=".agents/skills"
CLAUDE_DIR=".claude/skills"
SKILLS=(
yagni
kiss
dry
solid
separation-of-concerns
law-of-demeter
boy-scout-rule
convention-over-configuration
detect-stack
)
echo "Installing coding-principles skills..."
echo ""
# Copy each skill directory
for skill in "${SKILLS[@]}"; do
src="${SCRIPT_DIR}/skills/${skill}"
dest="${AGENTS_DIR}/${skill}"
if [ ! -d "${src}" ]; then
echo " ! skills/${skill} not found, skipping"
continue
fi
mkdir -p "${dest}"
cp -r "${src}/"* "${dest}/"
echo " + ${skill}"
# Create .claude/skills/ symlink
mkdir -p "${CLAUDE_DIR}"
link="${CLAUDE_DIR}/${skill}"
if [ -L "${link}" ]; then
rm "${link}"
elif [ -d "${link}" ]; then
rm -rf "${link}"
fi
ln -s "../../${AGENTS_DIR}/${skill}" "${link}"
done
echo ""
echo "Installed to:"
echo " .agents/skills/ (actual files)"
echo " .claude/skills/ (symlinks)"
echo ""
echo "Next: ask your agent to run detect-stack to generate .agents/stack-context.md"