claude-all-config 3.8.3 → 3.8.4

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/.env.example CHANGED
@@ -50,3 +50,8 @@ TELEGRAM_API_HASH=
50
50
  # ANTHROPIC_API_KEY=
51
51
  # OPENAI_API_KEY=
52
52
  # GOOGLE_API_KEY=
53
+
54
+ # ─────────────────────────────────────────────────────────────
55
+ # GitHub token for ai-memory private repo sync
56
+ # ─────────────────────────────────────────────────────────────
57
+ GH_TOKEN=
@@ -0,0 +1,60 @@
1
+ #!/usr/bin/env bash
2
+ # ai-memory — Sync shared AI context across devices
3
+ # Usage:
4
+ # ai-memory pull — Load latest context (session start)
5
+ # ai-memory push — Push session summary (session end)
6
+ # ai-memory context — Print CONTEXT.md + active-tasks for injection
7
+
8
+ set -euo pipefail
9
+
10
+ REPO_URL="${AI_MEMORY_REPO:-https://github.com/zesbe/ai-memory.git}"
11
+ MEMORY_DIR="${AI_MEMORY_DIR:-$HOME/ai-memory}"
12
+
13
+ # Use GH token from env if available (for private repos)
14
+ if [[ -n "${GH_TOKEN:-}" ]]; then
15
+ REPO_URL="https://x-access-token:${GH_TOKEN}@github.com/zesbe/ai-memory.git"
16
+ elif [[ -n "${GITHUB_TOKEN:-}" ]]; then
17
+ REPO_URL="https://x-access-token:${GITHUB_TOKEN}@github.com/zesbe/ai-memory.git"
18
+ fi
19
+
20
+ # Ensure repo exists locally
21
+ ensure_repo() {
22
+ if [[ ! -d "$MEMORY_DIR/.git" ]]; then
23
+ git clone --depth 1 "$REPO_URL" "$MEMORY_DIR" 2>/dev/null
24
+ fi
25
+ }
26
+
27
+ case "${1:-context}" in
28
+ pull)
29
+ ensure_repo
30
+ cd "$MEMORY_DIR"
31
+ git pull --rebase --quiet 2>/dev/null || true
32
+ echo "✅ ai-memory synced"
33
+ ;;
34
+ push)
35
+ ensure_repo
36
+ cd "$MEMORY_DIR"
37
+ git add -A
38
+ if git diff --cached --quiet 2>/dev/null; then
39
+ echo "No changes to push"
40
+ else
41
+ git commit -m "auto: session update $(date +%Y-%m-%d_%H:%M)" --quiet
42
+ git push --quiet 2>/dev/null
43
+ echo "✅ ai-memory pushed"
44
+ fi
45
+ ;;
46
+ context)
47
+ ensure_repo
48
+ cd "$MEMORY_DIR"
49
+ git pull --rebase --quiet 2>/dev/null || true
50
+ echo "--- AI MEMORY CONTEXT ---"
51
+ cat "$MEMORY_DIR/CONTEXT.md" 2>/dev/null
52
+ echo ""
53
+ echo "--- ACTIVE TASKS ---"
54
+ cat "$MEMORY_DIR/active-tasks/current.md" 2>/dev/null
55
+ echo "--- END AI MEMORY ---"
56
+ ;;
57
+ *)
58
+ echo "Usage: ai-memory [pull|push|context]"
59
+ ;;
60
+ esac
@@ -17,6 +17,13 @@ fi
17
17
  # Read using-superpowers content
18
18
  using_superpowers_content=$(cat "${PLUGIN_ROOT}/skills/using-superpowers/SKILL.md" 2>&1 || echo "Error reading using-superpowers skill")
19
19
 
20
+ # Load ai-memory context if available
21
+ ai_memory_content=""
22
+ AI_MEMORY_SCRIPT="${SCRIPT_DIR}/ai-memory.sh"
23
+ if [[ -f "$AI_MEMORY_SCRIPT" ]]; then
24
+ ai_memory_content=$(bash "$AI_MEMORY_SCRIPT" context 2>/dev/null || echo "")
25
+ fi
26
+
20
27
  # Escape outputs for JSON using pure bash
21
28
  escape_for_json() {
22
29
  local input="$1"
@@ -38,13 +45,14 @@ escape_for_json() {
38
45
 
39
46
  using_superpowers_escaped=$(escape_for_json "$using_superpowers_content")
40
47
  warning_escaped=$(escape_for_json "$warning_message")
48
+ ai_memory_escaped=$(escape_for_json "$ai_memory_content")
41
49
 
42
50
  # Output context injection as JSON
43
51
  cat <<EOF
44
52
  {
45
53
  "hookSpecificOutput": {
46
54
  "hookEventName": "SessionStart",
47
- "additionalContext": "<EXTREMELY_IMPORTANT>\nYou have superpowers.\n\n**Below is the full content of your 'superpowers:using-superpowers' skill - your introduction to using skills. For all other skills, use the 'Skill' tool:**\n\n${using_superpowers_escaped}\n\n${warning_escaped}\n</EXTREMELY_IMPORTANT>"
55
+ "additionalContext": "<EXTREMELY_IMPORTANT>\nYou have superpowers.\n\n**Below is the full content of your 'superpowers:using-superpowers' skill - your introduction to using skills. For all other skills, use the 'Skill' tool:**\n\n${using_superpowers_escaped}\n\n${warning_escaped}\n\n${ai_memory_escaped}\n</EXTREMELY_IMPORTANT>"
48
56
  }
49
57
  }
50
58
  EOF
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claude-all-config",
3
- "version": "3.8.3",
3
+ "version": "3.8.4",
4
4
  "description": "🦾 MONSTER ENGINEER v2 - Ultimate AI CLI with 63 Skills, 12 Superpowers, 14 Agents. Multi-Agent Orchestration, Cost-Aware, Security Scorecard, Parallel-First.",
5
5
  "main": "index.js",
6
6
  "bin": {