Skip to content

CLI Usage

Peterson Fernandes edited this page Aug 15, 2026 · 1 revision

CLI Usage

Identical to RAHasher 1.8.3:

RetroAchievementsSharp [-v] [-s systempath] system filepath...
  • -v — verbose messages for debugging
  • -s systempath — directory with aes_keys.txt / seeddb.bin (3DS)
  • system — console key (case-insensitive) or numeric id; ? auto-detects by trying every console
  • filepath — file(s) to hash; may contain wildcards in the filename

Examples:

RetroAchievementsSharp NES game.nes
RetroAchievementsSharp PS1 disc.cue
RetroAchievementsSharp -s C:\RetroArch\system 3DS game.cia

Exit codes: 0 success, 1 any failure.

Quirk faithfully reproduced from the original: console keys are only accepted for consoles with a non-empty RA group; NULL-group consoles (Oric, TI83, TIC-80, ESCV, DOS, 3DS, …) must be addressed by numeric id — e.g. RetroAchievementsSharp 62 game.cia.

scan — hash a whole ROM library

RetroAchievementsSharp scan [options] <path>...
  -f, --format <text|csv|json>  output format (default: text)
  -s <systempath>               supplementary files directory (3DS keys)
      --match <db.json>         RetroAchievements database snapshot
      --move <dir>              move matched files into <dir>/<console-key>/
      --dry-run                 preview --move without moving anything
      --no-recursive            do not descend into subdirectories
  -h, --help                    show help

Each file is auto-detected the same way the ? system key works for a single file; matched rows append => <Title> (ID <id>). The manifest goes to stdout, the summary to stderr; exit code 0 when every file hashed, 1 when any failed.

Other subcommands

  • RetroAchievementsSharp consoles [--format text|csv|json] — dump the console table.
  • RetroAchievementsSharp checkkeys [-s <systempath>] — validate 3DS key files.
  • RetroAchievementsSharp identify <system> <file> [--db <RetroAchievements.json> | --user <u> --api-key <k>] — hash one file and resolve it to a game with achievements.
  • RetroAchievementsSharp fetch-db <url-or-path> [--out <file>] — download a database snapshot, validate it, save atomically.

Logging and bug reports

All logging goes through Serilog. Warning+ events are forwarded to the bug report API unless disabled:

Variable Purpose
RASHARP_BUGREPORT_API_KEY override the built-in API key
RASHARP_BUGREPORT_URL endpoint override
RASHARP_BUGREPORT_DISABLE set to 1 to force forwarding off
RASHARP_STATS_DISABLE set to 1 to disable usage telemetry

Clone this wiki locally