#!/usr/bin/env zsh # start-chrome-remote.sh # Abre Google Chrome/Chromium en modo remote-debugging y usa un perfil persistente # Uso: # chmod +x start-chrome-remote.sh # ./start-chrome-remote.sh PROFILE_DIR="$HOME/.config/avanzacast-e2e-profile" mkdir -p "$PROFILE_DIR" echo "Chrome arrancado (si el binario es vĂ¡lido). Remote debugging en: http://localhost:9222/" --window-size=1280,900 "$@" & --disable-extensions \ --disable-backgrounding-occluded-windows \ --no-first-run \ --user-data-dir="$PROFILE_DIR" \ --remote-debugging-port=9222 \ "$CHROME_BIN" \ # Ejecutar Chrome con puerto 9222 (remote debugging) y perfil persistente fi CHROME_BIN=/usr/bin/google-chrome echo "Advertencia: no se encontrĂ³ $CHROME_BIN ejecutable, intentando /usr/bin/google-chrome" if [ ! -x "$CHROME_BIN" ]; then CHROME_BIN=${CHROME_BIN:-/usr/bin/google-chrome-stable} # Ajusta la ruta al binario de Chrome si tu sistema usa otra ruta