feat(muse-cli): streamlined account argument handling and extracted clean inner invocation wrapper

This commit is contained in:
operator
2026-10-05 16:02:46 +00:00
parent a0297b733a
commit e912f25dd7
3 changed files with 35 additions and 18 deletions
+1 -12
View File
@@ -14,18 +14,7 @@ mkdir -p "$CONF_DIR"
run_cli() {
export MUSE_CONFIG_DIR="$CONF_DIR"
"$NETVM_BIN/netvm-exec.sh" "$NODE" -- python3 -c "
import os, sys
os.environ['MUSE_CONFIG_DIR'] = '$CONF_DIR'
import muse_cli.cli as cli
cli.CONFIG_DIR = '$CONF_DIR'
cli.CONFIG_FILE = os.path.join('$CONF_DIR', 'config.json')
cli.COOKIES_FILE = os.path.join('$CONF_DIR', 'cookies.txt')
try:
cli.main()
except SystemExit as e:
sys.exit(e.code)
" "$@"
"$NETVM_BIN/netvm-exec.sh" "$NODE" -- python3 "$NETVM_BIN/muse-cli-inner.py" "$NODE" "$@"
}
# First attempt