subconscious-cli 4.1.1 → 4.1.2
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/README.md +5 -2
- package/bin/native/subc-tui-darwin-amd64 +0 -0
- package/bin/native/subc-tui-darwin-arm64 +0 -0
- package/bin/native/subc-tui-linux-amd64 +0 -0
- package/bin/native/subc-tui-linux-arm64 +0 -0
- package/bin/native/subc-tui-windows-amd64.exe +0 -0
- package/bin/native/subc-tui-windows-arm64.exe +0 -0
- package/bin/registry.generated.json +2 -5
- package/bin/runbook/subconscious-code/install.sh +51 -17
- package/bin/runbook/subconscious-code/run.sh +3 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -204,8 +204,11 @@ Starting with CLI 4.1.1, `subc marathon` is the native agent command. On Windows
|
|
|
204
204
|
the installer writes `marathon.exe`, avoiding the system `sc.exe` command.
|
|
205
205
|
`subc sc` remains a compatibility alias but never launches Windows service
|
|
206
206
|
control. Older pinned release binaries are also installed as `marathon.exe`.
|
|
207
|
-
|
|
208
|
-
|
|
207
|
+
Starting with CLI 4.1.2 and native agent 0.1.6, macOS and Linux also install
|
|
208
|
+
and launch `marathon`. Existing `.sc` settings, sessions, and `SC_*` variables
|
|
209
|
+
are preserved on every platform. Shell behavior is unchanged. Older Unix
|
|
210
|
+
release archives are installed under the new name; existing `sc` files are
|
|
211
|
+
left untouched. `subc sc` remains a compatibility alias on every platform.
|
|
209
212
|
|
|
210
213
|
`subc codex` disables Codex apps and plugin tools for that launch by default so
|
|
211
214
|
requests remain below the gateway's 128-tool limit. Core coding tools remain
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -33,10 +33,7 @@
|
|
|
33
33
|
],
|
|
34
34
|
"protocol": "openai",
|
|
35
35
|
"homepage": "https://github.com/subconscious-systems/subconscious-code",
|
|
36
|
-
"bin": "
|
|
37
|
-
"binByPlatform": {
|
|
38
|
-
"win32": "marathon"
|
|
39
|
-
},
|
|
36
|
+
"bin": "marathon",
|
|
40
37
|
"install": {
|
|
41
38
|
"darwin": "subc marathon install",
|
|
42
39
|
"linux": "subc marathon install",
|
|
@@ -54,7 +51,7 @@
|
|
|
54
51
|
],
|
|
55
52
|
"setupNeedsAuth": false
|
|
56
53
|
},
|
|
57
|
-
"launch": "
|
|
54
|
+
"launch": "marathon",
|
|
58
55
|
"env": {
|
|
59
56
|
"SC_BASE_URL": "{baseUrlV1}",
|
|
60
57
|
"SC_DLR_URL": "{baseUrl}",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
|
-
# Install a precompiled
|
|
2
|
+
# Install a precompiled Marathon release for the current platform.
|
|
3
3
|
|
|
4
4
|
set -euo pipefail
|
|
5
5
|
|
|
@@ -9,9 +9,9 @@ INSTALL_DIR="${SC_INSTALL_DIR:-${HOME}/.local/bin}"
|
|
|
9
9
|
|
|
10
10
|
usage() {
|
|
11
11
|
cat <<'EOF'
|
|
12
|
-
Usage: subc
|
|
12
|
+
Usage: subc marathon install
|
|
13
13
|
|
|
14
|
-
Install the latest
|
|
14
|
+
Install the latest Marathon release. Linux downloads and verifies the
|
|
15
15
|
published static binary. macOS downloads and verifies the matching native binary.
|
|
16
16
|
EOF
|
|
17
17
|
}
|
|
@@ -23,7 +23,7 @@ case "${1:-install}" in
|
|
|
23
23
|
exit 0
|
|
24
24
|
;;
|
|
25
25
|
*)
|
|
26
|
-
echo "error: unsupported
|
|
26
|
+
echo "error: unsupported Marathon setup action: $1" >&2
|
|
27
27
|
usage >&2
|
|
28
28
|
exit 2
|
|
29
29
|
;;
|
|
@@ -60,8 +60,8 @@ architecture="$(uname -m)"
|
|
|
60
60
|
version="$(release_tag || true)"
|
|
61
61
|
|
|
62
62
|
if [[ -z "$version" ]]; then
|
|
63
|
-
echo "error: no published
|
|
64
|
-
echo "The release may still be building. Retry subc
|
|
63
|
+
echo "error: no published Marathon release is available yet" >&2
|
|
64
|
+
echo "The release may still be building. Retry subc marathon install after it finishes." >&2
|
|
65
65
|
exit 1
|
|
66
66
|
fi
|
|
67
67
|
|
|
@@ -76,27 +76,51 @@ case "${platform}:${architecture}" in
|
|
|
76
76
|
;;
|
|
77
77
|
esac
|
|
78
78
|
|
|
79
|
-
|
|
79
|
+
executable="marathon"
|
|
80
|
+
asset="${executable}-${target}.tar.gz"
|
|
80
81
|
checksum="${asset}.sha256"
|
|
81
|
-
work_dir="$(mktemp -d "${TMPDIR:-/tmp}/subc-
|
|
82
|
+
work_dir="$(mktemp -d "${TMPDIR:-/tmp}/subc-marathon-install.XXXXXX")"
|
|
83
|
+
staging=''
|
|
82
84
|
cleanup() {
|
|
83
|
-
rm -f "$work_dir/$asset" "$work_dir/$checksum" "$work_dir/sc"
|
|
85
|
+
rm -f "$work_dir/$asset" "$work_dir/$checksum" "$work_dir/sc" "$work_dir/marathon"
|
|
86
|
+
if [[ -n "$staging" ]]; then rm -f "$staging"; fi
|
|
84
87
|
rmdir "$work_dir" 2>/dev/null || true
|
|
85
88
|
}
|
|
86
89
|
trap cleanup EXIT HUP INT TERM
|
|
87
90
|
|
|
88
|
-
echo "Downloading
|
|
91
|
+
echo "Downloading Marathon v${version} for ${target}..."
|
|
89
92
|
if command -v gh >/dev/null 2>&1 \
|
|
90
|
-
&& gh release view "v${version}" --repo "$REPOSITORY" >/dev/null
|
|
93
|
+
&& assets="$(gh release view "v${version}" --repo "$REPOSITORY" --json assets --jq '.assets[].name' 2>/dev/null)"; then
|
|
94
|
+
if ! printf '%s\n' "$assets" | grep -Fxq "$asset"; then
|
|
95
|
+
# Pinned legacy releases are still installed as marathon, never as sc.
|
|
96
|
+
executable="sc"
|
|
97
|
+
asset="${executable}-${target}.tar.gz"
|
|
98
|
+
checksum="${asset}.sha256"
|
|
99
|
+
fi
|
|
100
|
+
if ! printf '%s\n' "$assets" | grep -Fxq "$asset" \
|
|
101
|
+
|| ! printf '%s\n' "$assets" | grep -Fxq "$checksum"; then
|
|
102
|
+
echo "error: release is missing $asset or $checksum" >&2
|
|
103
|
+
exit 1
|
|
104
|
+
fi
|
|
91
105
|
gh release download "v${version}" --repo "$REPOSITORY" \
|
|
92
106
|
--pattern "$asset" --pattern "$checksum" --dir "$work_dir"
|
|
93
107
|
else
|
|
94
108
|
command -v curl >/dev/null 2>&1 || {
|
|
95
|
-
echo "error: curl is required to download
|
|
109
|
+
echo "error: curl is required to download Marathon" >&2
|
|
96
110
|
exit 1
|
|
97
111
|
}
|
|
98
112
|
release_url="${REPOSITORY_URL}/releases/download/v${version}"
|
|
99
|
-
curl -
|
|
113
|
+
status="$(curl -sSL -w '%{http_code}' "${release_url}/${asset}" -o "$work_dir/$asset")"
|
|
114
|
+
if [[ "$status" == 404 ]]; then
|
|
115
|
+
rm -f "$work_dir/$asset"
|
|
116
|
+
executable="sc"
|
|
117
|
+
asset="${executable}-${target}.tar.gz"
|
|
118
|
+
checksum="${asset}.sha256"
|
|
119
|
+
curl -fL "${release_url}/${asset}" -o "$work_dir/$asset"
|
|
120
|
+
elif [[ "$status" != 200 ]]; then
|
|
121
|
+
echo "error: Marathon download failed (HTTP $status)" >&2
|
|
122
|
+
exit 1
|
|
123
|
+
fi
|
|
100
124
|
curl -fL "${release_url}/${checksum}" -o "$work_dir/$checksum"
|
|
101
125
|
fi
|
|
102
126
|
|
|
@@ -106,7 +130,7 @@ elif command -v shasum >/dev/null 2>&1; then
|
|
|
106
130
|
expected="$(awk '{print $1}' "$work_dir/$checksum")"
|
|
107
131
|
actual="$(shasum -a 256 "$work_dir/$asset" | awk '{print $1}')"
|
|
108
132
|
[[ "$actual" == "$expected" ]] || {
|
|
109
|
-
echo "error:
|
|
133
|
+
echo "error: Marathon checksum verification failed" >&2
|
|
110
134
|
exit 1
|
|
111
135
|
}
|
|
112
136
|
else
|
|
@@ -114,7 +138,17 @@ else
|
|
|
114
138
|
exit 1
|
|
115
139
|
fi
|
|
116
140
|
|
|
117
|
-
tar -xzf "$work_dir/$asset" -C "$work_dir"
|
|
141
|
+
tar -xzf "$work_dir/$asset" -C "$work_dir" "$executable"
|
|
142
|
+
if [[ ! -f "$work_dir/$executable" || -L "$work_dir/$executable" ]]; then
|
|
143
|
+
echo "error: release has no regular root $executable executable" >&2
|
|
144
|
+
exit 1
|
|
145
|
+
fi
|
|
118
146
|
mkdir -p "$INSTALL_DIR"
|
|
119
|
-
|
|
120
|
-
echo "
|
|
147
|
+
if [[ -d "$INSTALL_DIR/marathon" ]]; then
|
|
148
|
+
echo "error: $INSTALL_DIR/marathon is a directory; refusing to replace it" >&2
|
|
149
|
+
exit 1
|
|
150
|
+
fi
|
|
151
|
+
staging="$(mktemp "$INSTALL_DIR/.marathon.XXXXXX")"
|
|
152
|
+
install -m 0755 "$work_dir/$executable" "$staging"
|
|
153
|
+
mv -f "$staging" "$INSTALL_DIR/marathon"
|
|
154
|
+
echo "Installed Marathon v${version} to $INSTALL_DIR/marathon"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
|
-
# Launch
|
|
2
|
+
# Launch Marathon without changing ~/.sc or project settings.
|
|
3
3
|
|
|
4
4
|
set -euo pipefail
|
|
5
5
|
|
|
@@ -8,7 +8,7 @@ API_KEY="${SC_API_KEY:-${API_KEY:-}}"
|
|
|
8
8
|
MODEL="${MODEL:-subconscious/glm-5.3-marathon}"
|
|
9
9
|
|
|
10
10
|
if [[ -z "$GATEWAY_URL" || -z "$API_KEY" ]]; then
|
|
11
|
-
echo "error: GATEWAY_URL and API_KEY are required to launch
|
|
11
|
+
echo "error: GATEWAY_URL and API_KEY are required to launch Marathon" >&2
|
|
12
12
|
exit 1
|
|
13
13
|
fi
|
|
14
14
|
|
|
@@ -18,4 +18,4 @@ export SC_DLR_URL="${GATEWAY_URL%/}"
|
|
|
18
18
|
export SC_DLR_ENABLED=true
|
|
19
19
|
export SC_MODEL="$MODEL"
|
|
20
20
|
|
|
21
|
-
exec
|
|
21
|
+
exec marathon "$@"
|
package/package.json
CHANGED