Merge the two separate container projects into a single image and management script. Both OpenCode and Claude Code are installed in the same Arch Linux image and share one persistent $HOME directory, which enables the opencode-claude-bridge plugin to read Claude CLI credentials from within OpenCode. Subcommands: opencode, claude, update, force-cleanup.
17 lines
421 B
Text
17 lines
421 B
Text
if [ -n "$BASH_VERSION" ]; then
|
|
AGENT_CONTAINER_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
elif [ -n "$ZSH_VERSION" ]; then
|
|
AGENT_CONTAINER_DIR="${0:A:h}"
|
|
fi
|
|
|
|
opencode() {
|
|
python3 "$AGENT_CONTAINER_DIR/agent-container.py" opencode "$@"
|
|
}
|
|
|
|
claude() {
|
|
python3 "$AGENT_CONTAINER_DIR/agent-container.py" claude "$@"
|
|
}
|
|
|
|
agent-container() {
|
|
python3 "$AGENT_CONTAINER_DIR/agent-container.py" "$@"
|
|
}
|