Skip to content

Settings file ​

The app and the command-line tool share one RustZ.ini and one custom dictionary, UserDict.txt. The app saves the file for you, so you rarely need to edit it.

Location ​

The first match wins:

  1. The folder in the environment variable RUSTZ_CONFIG_DIR.
  2. The program's own folder — if it contains a RustZ.ini (portable mode: carry the whole folder around, as with ConvertZ). On macOS and Linux it is ignored if that folder, the settings file or the dictionary is writable by other users, so nobody else can slip in settings or entries that change your results. The settings page and rustz-cli /? say when portable mode is active.
  3. The usual per-user folder:
PlatformLocation
macOS~/Library/Application Support/RustZ/
Windows%APPDATA%\RustZ\
Linux$XDG_CONFIG_HOME/rustz/, by default ~/.config/rustz/

The last line of rustz-cli /? shows which settings file is in use.

Format ​

Plain INI: [section], key=value, and comments starting with ; or #. Booleans are 1/0 (true/false also work). Missing keys and values that cannot be read fall back to the defaults.

[Data] ​

The same keys as ConvertZ's ConCmd.ini:

KeyDefaultMeaning
Ignoresee belowFile types skipped when adding folders or expanding wildcards, comma-separated
HtmlType*.htm*,*.shtm*,*.xhtm*,*.asp,*.aspx,*.jsp,*.php*,*.pl,*.cgi,*.jsWeb-page types: missing characters become &#NNNN; and charset declarations are fixed
FixHtmlCharset1Fix charset declarations in web pages
AddBOMtoUTF80Add a BOM to UTF-8 output
ConvertNCR0Turn &#NNNN; into text (/cu on the command line)

The default Ignore list:

text
*.exe,*.dll,*.ocx,*.com,*.sys,*.vxd,*.drv,*.so,*.dylib,*.o,*.a,*.lib,*.obj,*.class,*.jar,*.pyc,
*.zip,*.z[0-9][0-9],*.rar,*.r[0-9][0-9],*.7z,*.lha,*.lzh,*.ar?,*.cab,*.tar,*.gz,*.tgz,*.bz2,*.xz,*.zst,*.bin,*.img,*.iso,*.dmg,
*.bmp,*.gif,*.jp*g,*.tif*,*.png,*.webp,*.heic,*.pcx,*.psd,*.ico,*.icns,*.svgz,
*.hlp,*.chm,*.pdf,*.doc,*.doc?,*.xl?,*.xl??,*.pp?,*.pp??,*.od?,*.md?,*.db,*.sqlite,
*.au,*.mid,*.wav,*.mp*,*.m4?,*.aac,*.flac,*.ape,*.og?,*.r*m,*.ra,*.avi,*.asf,*.wm*,*.mov,*.mkv,*.webm,*.swf,
*.ttf,*.otf,*.ttc,*.woff*,*.lnk,*.torrent,*.bak,*.ds_store

(It is a single line; it is wrapped here for reading.) Patterns support *, ? and character sets like [abc], [0-9] and [!a], case-insensitive.

[Chinese] ​

KeyDefaultValues
Engineopenccopencc, convertz
Varianttwtw, hk, std
RegionalPhrases1Convert Taiwan vocabulary
ConvertZFix1Apply the fix lists in the ConvertZ engine
UserDict1Use the custom dictionary

[GUI] ​

State of the app; the command-line tool ignores it:

KeyDefaultMeaning
Themesystemsystem, light, dark
UiScale1Interface scale, 0.6–2.0
KeepRunning1Keep running after the window is closed
SourceautoSource encoding for file conversion: auto or an encoding code
Targetutf8Target encoding for file conversion
Faceautoauto, t, s, d
OutputToDir01 saves to a folder, 0 overwrites the originals
OutputDir(empty)The folder to save to
Backup1Back up as .bak (or .1.bak…) before overwriting
Recursive1Include subfolders when adding folders
PreviewKB16Preview length in KB, 1–1024
LastDir(empty)Last folder used in a file dialog

Example ​

ini
[Data]
Ignore=*.exe,*.dll,*.zip,*.png,*.jpg
HtmlType=*.htm*,*.php*
FixHtmlCharset=1
AddBOMtoUTF8=0
ConvertNCR=0

[Chinese]
Engine=opencc
Variant=tw
RegionalPhrases=1
ConvertZFix=1
UserDict=1

Custom dictionary ​

UserDict.txt lives next to RustZ.ini. Its format is described under Custom dictionary.

Tables derived from ConvertZ are for personal, non-commercial use. OpenCC dictionaries are Apache-2.0.