Gadgets

You can create custom actions (gadgets) that run external tools. There are two types of gadgets:

🐧 Gadgets are regular actions. They have an action identifier, and you can bind hotkeys to them.

Gadgets are configured in conf.json.

Adding an Application Launcher

gadgets [
    {
        id "gadget.action.my.application.runner"
        name "My Application Runner"
        type "application"

        application "Application Name"
        "files" [ "${active.selection.paths}" ]
    }
]

🐧 files option is optional.

Adding an Executable Launcher

gadgets [
    {
        id "gadget.action.my.executable.runner"
        name "My Executable Runner"
        type "executable"

        executable "/bin/command"
        args ["${active.selection.paths}", "--some-option"]
        workingDirectory "${user.home}"
    }
]

🐧 args and workingDirectory options are optional.

Available Variables

You can use state variables in files. Here is the list of available variables:

Variable nameDescription
${active.selection.paths}Selected item paths (active pane) (*)
${active.selection.names}Selected item names (active pane) (*)
${inactive.selection.paths}Selected item paths (inactive pane) (*)
${inactive.selection.names}Selected item names (inactive pane) (*)
${current.file.path}Current file path (active pane)
${current.file.name}Current file name (active pane)
${active.folder.path}Current folder path (active pane)
${inactive.folder.path}Current folder path (inactive pane)
${user.home}User home directory

Variables with an asterisk mark (*) might be substituted to several arguments (if several files are selected).