Skip to content

Logging

Debug logs

It is required to submit a debug log with any bug reports. Igir has many options, and every person's scenario is different, so a debug log is critical to reproduce the issue.

To generate this debug log, provide the option:

--debug-log

This will write the log file to the current working directory. You can provide a file path to the option if you want to write it somewhere else:

--debug-log <path>

Debug logs will always be written with the most verbose log level.

Log levels

By default, Igir will print the following log levels:

  • ERROR: an unexpected error has prevented an intended command
  • WARN: a preventable error has prevented an intended command

There are additional levels of verbosity that can be enabled with the -v flag:

  • INFO (-v): print information about actions taken.

    This includes:

    • Files being copied, zipped, and linked
    • dir2dat files being created
    • Fixdat files being created
    • Leftover input files deleted after being moved
    • Output files being cleaned (including files skipped due to --clean-dry-run)
    • Report files being created

    Usage:

    igir [commands..] [options] -v
    

    This level is helpful to turn on if you want to know every action that is resulting in a file being created, modified, or deleted.

  • DEBUG (-vv): print information about actions taken and skipped.

    This includes:

    • Everything from the INFO level above
    • Files skipped from being copied, zipped, or linked because the output file exists and an --overwrite option wasn't provided
    • Fixdat files skipped from being created because all games were found

    Usage:

    igir [commands..] [options] -vv
    

    This level is helpful to turn on if you want to debug why an action didn't take place.

  • TRACE (-vvv): print information about actions taken, skipped, and additional information that can be helpful to debug issues.

    Usage:

    igir [commands..] [options] -vvv
    

    Note

    Trace logs are required when submitting bug reports as they include information that can help diagnose your unique situation!

Output redirection

Igir is smart enough to detect if the standard output is a TTY terminal or not, and if it is not, will not render progress bars and may format log lines differently. This lets you safely pipe the output of Igir:

igir [commands..] [options] > out.log
igir [commands..] [options] | tee out.log
igir [commands..] [options] > out.log
igir [commands..] [options] | tee out.log