FatRat

Command Line

The desktop program is started with fatrat. A headless build, without the desktop window, is installed as fatrat-nogui. Both take the same options, except where noted below.

fatrat [options] [links ...]

fatrat --help prints the options your build supports. The manual page, man fatrat, lists most of them (it has no entry for --rest-socket).

Options

Options are case-insensitive, and each is given separately. Options that take a value (-c, -p, -u, --rest-socket) read the next argument as the value. If it is missing, FatRat prints a message and exits with status 1.

-f, --force
Start even if FatRat is already running. See "One instance at a time" below.
-i, --hidden
Desktop only. Start with the main window hidden. This works only if the tray icon exists. fatrat-nogui accepts the option and ignores it.
-n, --nogui
Desktop only. Start with no window at all. FatRat keeps running in the background, and you control it with the web interface or the terminal interface. fatrat-nogui does this without the option, and accepts the option too.
-d, --daemon
Run in the background as a daemon. This implies --nogui.
-c, --config file
Use file (an INI file) to store the settings, instead of the default settings file, ~/.config/Dolezel/fatrat.conf. The fatrat-conf command takes the same option.
--rest-socket path
Also serve the REST API on a Unix socket at path. The socket has no authentication and mode 0600. It is available only if FatRat was built with the web interface; otherwise FatRat prints a message and exits with status 1. See REST API.
--syslog
Also send the contents of the global log to syslog.
-p, --pidfile file
Write the process ID to file. FatRat removes the file when it exits normally.
-u, --user user[:group]
Run as user (and as group, if given) instead of the user who started FatRat. Use it when you start FatRat as root. If you leave out the group, FatRat uses the primary group of user. When started as root, it also replaces the supplementary groups with those of user. The process ID file, if any, is handed over to user, so FatRat can still remove it on exit.
--no-python
Turn off support for Python extensions. This option is listed only if FatRat was built with extension support. See Extensions.
-h, --help
Print the list of options and exit.

The options are read from left to right as they are found. The -i and -n options are not listed by --help in a build without the desktop window. For running FatRat as a service, see Running on a Server.

Passing links

Any argument that does not start with - is a link. To open the New transfer dialog with the links already filled in, pass them as arguments:

fatrat "http://example.com/a.zip" "http://example.com/b.zip"

This works only with the desktop window. The headless fatrat-nogui does not show a dialog, and ignores the links.

One instance at a time

At startup FatRat asks D-Bus whether another instance is already running. If one is, FatRat does not start a second one, and exits with status 0 after one of these:

Pass --force to skip the check. Without D-Bus support in the build, FatRat does not make the check at all.

Exit status

Unknown options

FatRat prints Ignoring unknown option and the option to the standard error output, and carries on. The argument after an unknown option is not skipped, so it is still used as a link or as the next option.