Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

CLI Options

Complete command line interface reference for Two-Face.

Usage

two-face [OPTIONS]

Connection Options

Lich Proxy Mode

OptionTypeDefaultDescription
--hoststring127.0.0.1Lich proxy hostname
--portinteger8000Lich proxy port
two-face --host 127.0.0.1 --port 8000

Direct eAccess Mode

OptionTypeRequiredDescription
--directflagYesEnable direct mode
--accountstringYesSimutronics account
--passwordstringYesAccount password
--gamestringYesGame instance
--characterstringYesCharacter name
two-face --direct \
  --account myaccount \
  --password mypassword \
  --game prime \
  --character Mycharacter

Game Instance Values

ValueGame
primeGemStone IV (Prime)
testGemStone IV (Test)
platGemStone IV (Platinum)
drDragonRealms (Prime)
drtDragonRealms (Test)

Configuration Options

OptionTypeDefaultDescription
--configpath~/.two-face/config.tomlMain config file
--layoutpath~/.two-face/layout.tomlLayout config file
--colorspath~/.two-face/colors.tomlColor theme file
--keybindspath~/.two-face/keybinds.tomlKeybinds file
--profilestringnoneLoad named profile
# Custom config location
two-face --config /path/to/config.toml

# Load profile
two-face --profile warrior

Logging Options

OptionTypeDefaultDescription
--debugflagfalseEnable debug logging
--log-filepath~/.two-face/two-face.logLog file location
--log-levelstringinfoLog verbosity

Log Levels

LevelDescription
errorErrors only
warnWarnings and errors
infoGeneral information (default)
debugDebug information
traceVerbose tracing
# Debug logging
two-face --debug

# Custom log file
two-face --log-file /tmp/debug.log --log-level trace

Display Options

OptionTypeDefaultDescription
--no-colorflagfalseDisable colors
--force-colorflagfalseForce color output
# Disable colors (for logging/piping)
two-face --no-color

Miscellaneous Options

OptionTypeDescription
--version, -VflagPrint version
--help, -hflagPrint help
--dump-configflagPrint default config
# Show version
two-face --version

# Show help
two-face --help

# Print default configuration
two-face --dump-config > ~/.two-face/config.toml

Option Precedence

Options are applied in this order (later overrides earlier):

  1. Default values
  2. Configuration files
  3. Environment variables
  4. Command line arguments

Examples

Basic Lich Connection

two-face --host 127.0.0.1 --port 8000

Direct Connection with Debug

two-face --direct \
  --account myaccount \
  --password mypassword \
  --game prime \
  --character Warrior \
  --debug

Custom Configuration

two-face \
  --config ~/games/two-face/config.toml \
  --layout ~/games/two-face/hunting.toml

Profile-Based Launch

# Assumes ~/.two-face/profiles/wizard.toml exists
two-face --profile wizard

Scripted Launch (Lich)

#!/bin/bash
# launch_gs4.sh

# Start Lich in background
lich &
sleep 5

# Connect Two-Face
two-face --host 127.0.0.1 --port 8000

Environment-Based (Direct)

#!/bin/bash
# Credentials from environment
export TF_ACCOUNT="myaccount"
export TF_PASSWORD="mypassword"
export TF_GAME="prime"

two-face --direct --character "$1"

Short Options

ShortLongDescription
-h--hostHost (Lich mode)
-p--portPort (Lich mode)
-c--configConfig file
-d--debugDebug mode
-V--versionVersion
# Short form
two-face -h 127.0.0.1 -p 8000 -d

Exit Codes

CodeMeaning
0Success
1General error
2Configuration error
3Connection error
4Authentication error

See Also