refactor: apply FAR-95 skills review follow-ups
- Remove `playwright-ephemeral/` and `shannon/` entirely per board direction - Fix `minimax-image-generation/SKILL.md` so YAML frontmatter is at line 1 - Add `minimax-image-generation/scripts/generate.sh` (argparse, error-checked, executable) and document invoking it via `bash scripts/generate.sh ...` - Deduplicate `minimax-image-generation/CLAUDE.md` against SKILL.md - `github-app-token`: write token to `$GH_CONFIG_DIR/.gh-token` (preferred) or `$AGENT_HOME/.gh-token` (fallback), fail loudly if neither is set instead of leaking to `mktemp` - Refresh root `CLAUDE.md` to match actual directory contents and patterns - Add root `README.md` with human-facing skills index Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
@@ -49,9 +49,20 @@ RESPONSE=$(curl -sf -X POST \
|
||||
TOKEN=$(echo "$RESPONSE" | jq -r '.token // empty')
|
||||
[[ -z "$TOKEN" ]] && die "No token in GitHub response: $RESPONSE"
|
||||
|
||||
# --- Write token to file ---
|
||||
GH_TOKEN_FILE="${AGENT_HOME:+${AGENT_HOME}/.gh-token}"
|
||||
GH_TOKEN_FILE="${GH_TOKEN_FILE:-$(mktemp)}"
|
||||
# --- Resolve token file location ---
|
||||
# Prefer GH_CONFIG_DIR (so the token lives alongside the per-agent gh config),
|
||||
# fall back to AGENT_HOME, fail loudly if neither is set rather than silently
|
||||
# writing to /tmp and leaking the token.
|
||||
if [[ -n "${GH_CONFIG_DIR:-}" ]]; then
|
||||
GH_TOKEN_DIR="$GH_CONFIG_DIR"
|
||||
elif [[ -n "${AGENT_HOME:-}" ]]; then
|
||||
GH_TOKEN_DIR="$AGENT_HOME"
|
||||
else
|
||||
die "Neither GH_CONFIG_DIR nor AGENT_HOME is set — refusing to write the token to a default location"
|
||||
fi
|
||||
|
||||
mkdir -p "$GH_TOKEN_DIR"
|
||||
GH_TOKEN_FILE="$GH_TOKEN_DIR/.gh-token"
|
||||
|
||||
printf '%s' "$TOKEN" > "$GH_TOKEN_FILE"
|
||||
chmod 600 "$GH_TOKEN_FILE"
|
||||
|
||||
Reference in New Issue
Block a user