diff --git a/digitalocean/codex.sh b/digitalocean/codex.sh index f3525322..d923c0ef 100755 --- a/digitalocean/codex.sh +++ b/digitalocean/codex.sh @@ -34,7 +34,7 @@ log_warn "Setting up environment variables..." inject_env_vars_ssh "$DO_SERVER_IP" upload_file run_server \ "OPENROUTER_API_KEY=$OPENROUTER_API_KEY" \ "OPENAI_API_KEY=$OPENROUTER_API_KEY" \ - "OPENAI_BASE_URL="https://openrouter.ai/api/v1"" + "OPENAI_BASE_URL=https://openrouter.ai/api/v1" echo "" log_info "DigitalOcean droplet setup completed successfully!" diff --git a/digitalocean/interpreter.sh b/digitalocean/interpreter.sh index d4bedccf..fac39c71 100755 --- a/digitalocean/interpreter.sh +++ b/digitalocean/interpreter.sh @@ -34,7 +34,7 @@ log_warn "Setting up environment variables..." inject_env_vars_ssh "$DO_SERVER_IP" upload_file run_server \ "OPENROUTER_API_KEY=$OPENROUTER_API_KEY" \ "OPENAI_API_KEY=$OPENROUTER_API_KEY" \ - "OPENAI_BASE_URL="https://openrouter.ai/api/v1"" + "OPENAI_BASE_URL=https://openrouter.ai/api/v1" echo "" log_info "DigitalOcean droplet setup completed successfully!" diff --git a/gcp/claude.sh b/gcp/claude.sh index e9eb8562..aa397b12 100755 --- a/gcp/claude.sh +++ b/gcp/claude.sh @@ -84,7 +84,7 @@ cat > "$SETTINGS_TEMP" << EOF } EOF -upload_file "$GCP_SERVER_IP" "$SETTINGS_TEMP" "~/.claude/settings.json" +upload_file "$GCP_SERVER_IP" "$SETTINGS_TEMP" "$HOME/.claude/settings.json" rm "$SETTINGS_TEMP" # Upload ~/.claude.json global state @@ -96,7 +96,7 @@ cat > "$GLOBAL_STATE_TEMP" << EOF } EOF -upload_file "$GCP_SERVER_IP" "$GLOBAL_STATE_TEMP" "~/.claude.json" +upload_file "$GCP_SERVER_IP" "$GLOBAL_STATE_TEMP" "$HOME/.claude.json" rm "$GLOBAL_STATE_TEMP" # Create empty CLAUDE.md diff --git a/gcp/nanoclaw.sh b/gcp/nanoclaw.sh index 509a20cb..793ef515 100755 --- a/gcp/nanoclaw.sh +++ b/gcp/nanoclaw.sh @@ -66,7 +66,7 @@ cat > "$DOTENV_TEMP" << EOF ANTHROPIC_API_KEY=${OPENROUTER_API_KEY} EOF -upload_file "$GCP_SERVER_IP" "$DOTENV_TEMP" "~/nanoclaw/.env" +upload_file "$GCP_SERVER_IP" "$DOTENV_TEMP" "$HOME/nanoclaw/.env" rm "$DOTENV_TEMP" echo "" diff --git a/gcp/openclaw.sh b/gcp/openclaw.sh index c2aa653d..ea4b7c95 100755 --- a/gcp/openclaw.sh +++ b/gcp/openclaw.sh @@ -92,7 +92,7 @@ cat > "$OPENCLAW_CONFIG_TEMP" << EOF } EOF -upload_file "$GCP_SERVER_IP" "$OPENCLAW_CONFIG_TEMP" "~/.openclaw/openclaw.json" +upload_file "$GCP_SERVER_IP" "$OPENCLAW_CONFIG_TEMP" "$HOME/.openclaw/openclaw.json" rm "$OPENCLAW_CONFIG_TEMP" echo "" diff --git a/modal/lib/common.sh b/modal/lib/common.sh index 4136ae1a..88bfa500 100644 --- a/modal/lib/common.sh +++ b/modal/lib/common.sh @@ -101,7 +101,8 @@ p.wait() upload_file() { local local_path="${1}" local remote_path="${2}" - local content=$(base64 -w0 "${local_path}" 2>/dev/null || base64 "${local_path}") + local content + content=$(base64 -w0 "${local_path}" 2>/dev/null || base64 "${local_path}") run_server "echo '${content}' | base64 -d > '${remote_path}'" } diff --git a/shared/common.sh b/shared/common.sh index 1e3b453e..33e94072 100644 --- a/shared/common.sh +++ b/shared/common.sh @@ -340,7 +340,8 @@ get_openrouter_api_key_manual() { start_oauth_server() { local port="${1}" local code_file="${2}" - local runtime=$(find_node_runtime) || { log_warn "No Node.js runtime found"; return 1; } + local runtime + runtime=$(find_node_runtime) || { log_warn "No Node.js runtime found"; return 1; } "${runtime}" -e " const http = require('http'); @@ -460,7 +461,8 @@ try_oauth_flow() { return 1 fi - local runtime=$(find_node_runtime) + local runtime + runtime=$(find_node_runtime) if [[ -z "${runtime}" ]]; then log_warn "No Node.js runtime (bun/node) found - OAuth server unavailable" return 1 @@ -1031,7 +1033,8 @@ ensure_ssh_key_with_provider() { # Register the key (provider-specific) log_warn "Registering SSH key with ${provider_name}..." - local key_name="spawn-$(hostname)-$(date +%s)" + local key_name + key_name="spawn-$(hostname)-$(date +%s)" if "${register_callback}" "${key_name}" "${pub_path}"; then log_info "SSH key registered with ${provider_name}" diff --git a/sprite/lib/common.sh b/sprite/lib/common.sh index 38fd9488..1e7cb688 100644 --- a/sprite/lib/common.sh +++ b/sprite/lib/common.sh @@ -88,7 +88,8 @@ setup_shell_environment() { log_warn "Configuring shell environment..." # Create temp file with path config - local path_temp=$(mktemp) + local path_temp + path_temp=$(mktemp) cat > "${path_temp}" << 'EOF' # [spawn:path] @@ -100,7 +101,8 @@ EOF rm "${path_temp}" # Switch bash to zsh - local bash_temp=$(mktemp) + local bash_temp + bash_temp=$(mktemp) cat > "${bash_temp}" << 'EOF' # [spawn:bash] exec /usr/bin/zsh -l @@ -119,7 +121,8 @@ inject_env_vars_sprite() { local sprite_name="${1}" shift - local env_temp=$(mktemp) + local env_temp + env_temp=$(mktemp) chmod 600 "${env_temp}" generate_env_config "$@" > "${env_temp}"