Skip to content
PyroScope Project edited this page Nov 12, 2017 · 16 revisions

rTorrent Scripting Explained

⚠️ This guide is still very incomplete — the best way to remedy that is to contribute what you know.

You can use the quite powerful GitHub search to find information on commands, e.g. their old vs. new syntax variants, what they actually do (i.e. “read the source”), and internal uses in predefined methods, handlers, and schedules. Consider the view.add example.

Commands Reference

  • method.* – Define new commands based on existing ones.
  • branch & if – Execute different commands depending on conditions.
  • execute[.*] – Call operating system commands, possibly catching their output for use within rTorrent.
  • schedule – Repeatedly execute commands, either in a given frequency, or at certain times.
  • convert.* – Commands that format values into strings.
  • system.* – Commands related to the operating system and the XMLRPC API.
  • ui.* – These commands control aspects of the ‘curses’ UI.

Variable types

This is a summary about the possible variable types in command_dynamic.cc (applies to v0.9.6).

Available types:

  • multi (with subtypes: static, private, const, rlookup)
    • TODO: what is it
  • simple (with subtypes: static, private, const)
    • TODO: why is it "simple"
  • value, bool, string, list (with subtypes: static, private, const)
    • Standard types, "value" is an integer.