This commit is contained in:
Reinier Criel 2025-11-06 08:32:25 -08:00
parent fa4c46c23d
commit f400c5576a
12 changed files with 59 additions and 213 deletions

View file

@ -7,6 +7,8 @@ remove_shim_from_path() {
echo "$PATH" | sed "s|$HOME/.safe-chain/shims:||g"
}
echo "[safe-chain debug] command -v {{AIKIDO_COMMAND}} (raw PATH): $(command -v {{AIKIDO_COMMAND}} 2>/dev/null || echo notfound)" >&2
echo "[safe-chain debug] PATH (raw): $PATH" >&2
if command -v {{AIKIDO_COMMAND}} >/dev/null 2>&1; then
# Remove shim directory from PATH when calling {{AIKIDO_COMMAND}} to prevent infinite loops
PATH=$(remove_shim_from_path) exec {{AIKIDO_COMMAND}} "$@"
@ -19,4 +21,4 @@ else
echo "Error: Could not find original {{PACKAGE_MANAGER}}" >&2
exit 1
fi
fi
fi