@a5c-ai/babysitter-github 0.1.5-staging.fd3ab4c2 → 5.0.1-staging.14c76959
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/hooks/session-end.ps1 +2 -1
- package/hooks/session-end.sh +5 -16
- package/hooks/session-start.ps1 +2 -1
- package/hooks/session-start.sh +2 -1
- package/hooks/user-prompt-submitted.ps1 +2 -1
- package/hooks/user-prompt-submitted.sh +5 -15
- package/package.json +2 -2
- package/plugin.json +5 -2
- package/skills/babysit/SKILL.md +2 -0
- package/versions.json +1 -1
package/hooks/session-end.ps1
CHANGED
|
@@ -30,7 +30,8 @@ if (-not $hasBabysitter) {
|
|
|
30
30
|
}
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
-
$
|
|
33
|
+
$GlobalRoot = if ($env:BABYSITTER_GLOBAL_STATE_DIR) { $env:BABYSITTER_GLOBAL_STATE_DIR } else { Join-Path $HOME ".a5c" }
|
|
34
|
+
$LogDir = if ($env:BABYSITTER_LOG_DIR) { $env:BABYSITTER_LOG_DIR } else { Join-Path $GlobalRoot "logs" }
|
|
34
35
|
$LogFile = Join-Path $LogDir "babysitter-session-end-hook.log"
|
|
35
36
|
New-Item -ItemType Directory -Path $LogDir -Force -ErrorAction SilentlyContinue | Out-Null
|
|
36
37
|
|
package/hooks/session-end.sh
CHANGED
|
@@ -15,24 +15,13 @@ set -uo pipefail
|
|
|
15
15
|
|
|
16
16
|
PLUGIN_ROOT="${COPILOT_PLUGIN_DIR:-$(cd "$(dirname "$0")/.." && pwd)}"
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
if [ -x "$HOME/.local/bin/babysitter" ]; then
|
|
22
|
-
export PATH="$HOME/.local/bin:$PATH"
|
|
23
|
-
else
|
|
24
|
-
# Last resort: npx fallback
|
|
25
|
-
SDK_VERSION=$(node -e "try{console.log(JSON.parse(require('fs').readFileSync('${PLUGIN_ROOT}/versions.json','utf8')).sdkVersion||'latest')}catch{console.log('latest')}" 2>/dev/null || echo "latest")
|
|
26
|
-
if [ -n "$SDK_VERSION" ]; then
|
|
27
|
-
babysitter() { npx -y "@a5c-ai/babysitter-sdk@${SDK_VERSION}" "$@"; }
|
|
28
|
-
else
|
|
29
|
-
# No CLI available at all -- exit silently
|
|
30
|
-
exit 0
|
|
31
|
-
fi
|
|
32
|
-
fi
|
|
18
|
+
if ! command -v babysitter &>/dev/null; then
|
|
19
|
+
# No CLI available — exit 0 (no-op, proceed with original command)
|
|
20
|
+
exit 0
|
|
33
21
|
fi
|
|
34
22
|
|
|
35
|
-
|
|
23
|
+
GLOBAL_ROOT="${BABYSITTER_GLOBAL_STATE_DIR:-$HOME/.a5c}"
|
|
24
|
+
LOG_DIR="${BABYSITTER_LOG_DIR:-${GLOBAL_ROOT}/logs}"
|
|
36
25
|
LOG_FILE="$LOG_DIR/babysitter-session-end-hook.log"
|
|
37
26
|
|
|
38
27
|
mkdir -p "$LOG_DIR" 2>/dev/null
|
package/hooks/session-start.ps1
CHANGED
|
@@ -14,7 +14,8 @@ $ErrorActionPreference = "Stop"
|
|
|
14
14
|
$PluginRoot = if ($env:COPILOT_PLUGIN_DIR) { $env:COPILOT_PLUGIN_DIR } else { Split-Path -Parent $PSScriptRoot }
|
|
15
15
|
$MarkerFile = Join-Path $PluginRoot ".babysitter-install-attempted"
|
|
16
16
|
|
|
17
|
-
$
|
|
17
|
+
$GlobalRoot = if ($env:BABYSITTER_GLOBAL_STATE_DIR) { $env:BABYSITTER_GLOBAL_STATE_DIR } else { Join-Path $HOME ".a5c" }
|
|
18
|
+
$LogDir = if ($env:BABYSITTER_LOG_DIR) { $env:BABYSITTER_LOG_DIR } else { Join-Path $GlobalRoot "logs" }
|
|
18
19
|
$LogFile = Join-Path $LogDir "babysitter-session-start-hook.log"
|
|
19
20
|
New-Item -ItemType Directory -Path $LogDir -Force -ErrorAction SilentlyContinue | Out-Null
|
|
20
21
|
|
package/hooks/session-start.sh
CHANGED
|
@@ -15,7 +15,8 @@ set -euo pipefail
|
|
|
15
15
|
PLUGIN_ROOT="${COPILOT_PLUGIN_DIR:-$(cd "$(dirname "$0")/.." && pwd)}"
|
|
16
16
|
MARKER_FILE="${PLUGIN_ROOT}/.babysitter-install-attempted"
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
GLOBAL_ROOT="${BABYSITTER_GLOBAL_STATE_DIR:-$HOME/.a5c}"
|
|
19
|
+
LOG_DIR="${BABYSITTER_LOG_DIR:-${GLOBAL_ROOT}/logs}"
|
|
19
20
|
LOG_FILE="$LOG_DIR/babysitter-session-start-hook.log"
|
|
20
21
|
mkdir -p "$LOG_DIR" 2>/dev/null
|
|
21
22
|
|
|
@@ -29,7 +29,8 @@ if (-not $hasBabysitter) {
|
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
$
|
|
32
|
+
$GlobalRoot = if ($env:BABYSITTER_GLOBAL_STATE_DIR) { $env:BABYSITTER_GLOBAL_STATE_DIR } else { Join-Path $HOME ".a5c" }
|
|
33
|
+
$LogDir = if ($env:BABYSITTER_LOG_DIR) { $env:BABYSITTER_LOG_DIR } else { Join-Path $GlobalRoot "logs" }
|
|
33
34
|
New-Item -ItemType Directory -Path $LogDir -Force -ErrorAction SilentlyContinue | Out-Null
|
|
34
35
|
|
|
35
36
|
# Capture stdin
|
|
@@ -8,23 +8,13 @@
|
|
|
8
8
|
|
|
9
9
|
PLUGIN_ROOT="${COPILOT_PLUGIN_DIR:-$(cd "$(dirname "$0")/.." && pwd)}"
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
export PATH="$HOME/.local/bin:$PATH"
|
|
15
|
-
else
|
|
16
|
-
SDK_VERSION=$(node -e "try{console.log(JSON.parse(require('fs').readFileSync('${PLUGIN_ROOT}/versions.json','utf8')).sdkVersion||'latest')}catch{console.log('latest')}" 2>/dev/null || echo "latest")
|
|
17
|
-
if [ -n "$SDK_VERSION" ]; then
|
|
18
|
-
babysitter() { npx -y "@a5c-ai/babysitter-sdk@${SDK_VERSION}" "$@"; }
|
|
19
|
-
export -f babysitter
|
|
20
|
-
else
|
|
21
|
-
# No CLI available -- exit silently
|
|
22
|
-
exit 0
|
|
23
|
-
fi
|
|
24
|
-
fi
|
|
11
|
+
if ! command -v babysitter &>/dev/null; then
|
|
12
|
+
# No CLI available — exit 0 (no-op, proceed with original command)
|
|
13
|
+
exit 0
|
|
25
14
|
fi
|
|
26
15
|
|
|
27
|
-
|
|
16
|
+
GLOBAL_ROOT="${BABYSITTER_GLOBAL_STATE_DIR:-$HOME/.a5c}"
|
|
17
|
+
LOG_DIR="${BABYSITTER_LOG_DIR:-${GLOBAL_ROOT}/logs}"
|
|
28
18
|
mkdir -p "$LOG_DIR" 2>/dev/null
|
|
29
19
|
|
|
30
20
|
INPUT_FILE=$(mktemp 2>/dev/null || echo "/tmp/hook-user-prompt-submitted-$$.json")
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@a5c-ai/babysitter-github",
|
|
3
|
-
"version": "0.1
|
|
3
|
+
"version": "5.0.1-staging.14c76959",
|
|
4
4
|
"description": "Babysitter orchestration plugin for GitHub Copilot CLI with lifecycle hooks and SDK-managed process-library bootstrapping",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "node scripts/sync-command-surfaces.js --check && node test/cloud-agent-install.test.js",
|
|
@@ -45,6 +45,6 @@
|
|
|
45
45
|
},
|
|
46
46
|
"homepage": "https://github.com/a5c-ai/babysitter/tree/main/plugins/babysitter-github#readme",
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@a5c-ai/babysitter-sdk": "
|
|
48
|
+
"@a5c-ai/babysitter-sdk": "5.0.1-staging.14c76959"
|
|
49
49
|
}
|
|
50
50
|
}
|
package/plugin.json
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "babysitter",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "5.0.1-staging.14c76959",
|
|
4
4
|
"description": "Orchestrate complex, multi-step workflows with event-sourced state management, hook-based extensibility, and human-in-the-loop approval -- powered by the Babysitter SDK",
|
|
5
|
-
"author": {
|
|
5
|
+
"author": {
|
|
6
|
+
"name": "a5c.ai",
|
|
7
|
+
"email": "support@a5c.ai"
|
|
8
|
+
},
|
|
6
9
|
"license": "MIT",
|
|
7
10
|
"skills": "skills/",
|
|
8
11
|
"hooks": "hooks.json",
|
package/skills/babysit/SKILL.md
CHANGED
|
@@ -18,6 +18,8 @@ Read the SDK version from `versions.json` to ensure version compatibility:
|
|
|
18
18
|
|
|
19
19
|
```bash
|
|
20
20
|
SDK_VERSION=$(node -e "try{console.log(JSON.parse(require('fs').readFileSync('${PLUGIN_ROOT}/versions.json','utf8')).sdkVersion||'latest')}catch{console.log('latest')}")
|
|
21
|
+
npm i -g @a5c-ai/babysitter-sdk@$SDK_VERSION
|
|
22
|
+
|
|
21
23
|
CLI="npx -y @a5c-ai/babysitter-sdk@$SDK_VERSION"
|
|
22
24
|
```
|
|
23
25
|
|
package/versions.json
CHANGED