-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·70 lines (61 loc) · 1.81 KB
/
Copy pathinstall.sh
File metadata and controls
executable file
·70 lines (61 loc) · 1.81 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
#!/bin/bash
# Install agent-issues skills and CLI commands.
#
# Usage:
# ./install.sh
#
# This installs the Python CLI with `uv tool install --editable`, then links
# the skills into Claude Code and Codex skill directories.
set -e
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
SKILLS_DIR="$SCRIPT_DIR/skills"
if ! command -v uv >/dev/null 2>&1; then
echo "Error: uv is required to install agent-issues." >&2
exit 1
fi
uv tool install --force --editable "$SCRIPT_DIR"
UV_BIN_DIR="$(uv tool dir --bin)"
# Claude Code global skills
CLAUDE_SKILLS="$HOME/.claude/skills"
mkdir -p "$CLAUDE_SKILLS"
for skill_dir in "$SKILLS_DIR"/*/; do
skill_name="$(basename "$skill_dir")"
target="$CLAUDE_SKILLS/$skill_name"
if [ -L "$target" ]; then
rm "$target"
elif [ -e "$target" ]; then
echo "Warning: $target exists and is not a symlink, skipping"
continue
fi
ln -s "$skill_dir" "$target"
echo "Linked: $target -> $skill_dir"
done
# Codex global skills
CODEX_HOME_DIR="${CODEX_HOME:-$HOME/.codex}"
CODEX_SKILLS="$CODEX_HOME_DIR/skills"
mkdir -p "$CODEX_SKILLS"
for skill_dir in "$SKILLS_DIR"/*/; do
skill_name="$(basename "$skill_dir")"
target="$CODEX_SKILLS/$skill_name"
if [ -L "$target" ]; then
rm "$target"
elif [ -e "$target" ]; then
echo "Warning: $target exists and is not a symlink, skipping"
continue
fi
ln -s "$skill_dir" "$target"
echo "Linked: $target -> $skill_dir"
done
echo ""
echo "Skills installed."
echo ""
echo "CLI tools installed via uv."
echo "Tool bin dir: $UV_BIN_DIR"
echo ""
echo "If the commands are not on your PATH yet, run:"
echo ""
echo " uv tool update-shell"
echo ""
echo "To get the shell wrappers plus cod/cld aliases in zsh, add this to ~/.zshrc:"
echo ""
echo " source $SCRIPT_DIR/agent-issues-zshrc.sh"