@echo off
chcp 65001 >nul 2>&1
title CGNI Wallet — open (testnet)
cd /d "%~dp0"

if not exist "cgni-wallet-cli.exe" (
  echo cgni-wallet-cli.exe not found.
  pause
  exit /b 1
)

if not exist "wallet" if not exist "wallet.keys" (
  echo Wallet file not found. Run create-wallet-en.bat or create-wallet-ru.bat first.
  echo.
  echo / Файл кошелька не найден. Сначала create-wallet-en.bat или create-wallet-ru.bat
  pause
  exit /b 1
)

set /p PASS=Password / Пароль: 
if "%PASS%"=="" exit /b 1

echo.
echo Opening testnet wallet. Remote node: cgnicoin.com:29778
echo For balance sync you need network access to the node.
echo.

cgni-wallet-cli.exe --testnet --wallet-file wallet --password "%PASS%" --daemon-address cgnicoin.com:29778 --trusted-daemon

pause
