@ddtcorex/dsh-maestro-supervisor 0.7.5 → 0.7.6
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/package.json
CHANGED
|
@@ -15,7 +15,15 @@ marker="${DSH_SUPERVISOR_MARKER:-$HOME/.dsh/.supervisor/planned-restart}"
|
|
|
15
15
|
# the script's own path — never a hard-coded location.
|
|
16
16
|
dsh_home="${DSH_HOME:-$HOME/.dsh}"
|
|
17
17
|
export SESSIONS_ROOT="${SESSIONS_ROOT:-$dsh_home/sessions}"
|
|
18
|
-
|
|
18
|
+
# Resolve the script's real location first: when invoked through a symlinked
|
|
19
|
+
# skill path (e.g. ~/.agents/skills/dsh-safe-restart/...), BASH_SOURCE keeps the
|
|
20
|
+
# link and "../../.." lands in ~/.agents — breaking the session-health preflight
|
|
21
|
+
# import (lib/session-health.js). readlink -f recovers the package checkout.
|
|
22
|
+
SCRIPT_SRC="${BASH_SOURCE[0]}"
|
|
23
|
+
if resolved="$(readlink -f "$SCRIPT_SRC" 2>/dev/null)" && [ -n "$resolved" ]; then
|
|
24
|
+
SCRIPT_SRC="$resolved"
|
|
25
|
+
fi
|
|
26
|
+
PLUGIN_DIR="${DSH_SUPERVISOR_PLUGIN_DIR:-$(cd "$(dirname "$SCRIPT_SRC")/../../.." && pwd)}"
|
|
19
27
|
confirmed=false
|
|
20
28
|
dry_run=false
|
|
21
29
|
auto_mode=false
|