Add container Git helper integration
Wire Git inside containers to the host proxy so HTTPS remotes can reuse host credentials automatically. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
1 parent
880b76f795
commit
69d029542b
2 files changed
+65
No files matched your search
Executable
+19
@@ -0,0 +1,19 @@
|
||||
#!/bin/sh
|
||||
set -eu
|
||||
|
||||
script_dir=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
||||
|
||||
if [ -n "${GIT_CRED_PROXY_RUNTIME:-}" ]; then
|
||||
exec "$GIT_CRED_PROXY_RUNTIME" "$script_dir/helper.mjs" "$@"
|
||||
fi
|
||||
|
||||
if command -v bun >/dev/null 2>&1; then
|
||||
exec bun "$script_dir/helper.mjs" "$@"
|
||||
fi
|
||||
|
||||
if command -v node >/dev/null 2>&1; then
|
||||
exec node "$script_dir/helper.mjs" "$@"
|
||||
fi
|
||||
|
||||
printf 'Either bun or node is required to run git-credential-hostproxy\n' >&2
|
||||
exit 1
|
||||
Reference in new issue
Block a user