IREXEC(1)

NAME

irexec - run programs with one button press

SYNOPSIS
irexec [options] [config_file]

DESCRIPTION

This program lets you execute arbitrary commands on an IR signal decoded by lircd, the LIRC daemon. You can give irexec a command line parameter which has to be a name of a valid config file. If no command line parameters are given irexec reads the default config file which is usually ~/.config/lircrc.

For version up to 0.9.1 irexec will wait until the executed program terminates. So append a '&' to the command string if you don't want that.

For version 0.9.2+ irexec does not wait for the executed program to terminate. In fact, the executed code is completely disconnected from irexec. So, for 0.9.2+ the trailing & is not required, and there is no way to make irexec wait for the executed code.

The config string consists of the shell command to be run. Potential uses are shutting down the computer, starting a dial-up connection etc.

OPTIONS

-h, --help
    Display usage summary

-v, --version
    Display version

-d, --daemon
    Make irexec fork to background. That way you can easily start irexec from an init script. In this case you should specify a config file on the command line as irexec won't be able to find your home directory.

-D, --loglevel [level]
    Determine the amount of logging information. [level] can be a symbolic syslog level: 'error','warning, 'info', 'notice' or 'debug'. lirc also defines three additional levels 'trace', 'trace1' and 'trace2' which gives even more messages ('trace2' bringing the most). However, in the log these messages are marked as 'debug'. By default, no logging is done.

-n, --name <name>
    Use this program name instead of the default 'irexec' as identifier in the lircd.conf file.

ENVIRONMENT

LIRC_SOCKET_PATH
    Path to the lircd socket irexec reads from, defaults to /var/run/lirc/lircd.

FILES

~/.cache/irexec.log
    Debug log. Setting the XDG_CACHE_HOME environment variable relocates this file to $XDG_CACHE_HOME/irexec.log

NOTE

If you start irexec, it reads your ~/.config/lircrc and reacts only on prog= entries that point to irexec. If you have included more than one program in your .lircrc, then start all these programs, they react itself only to their according entries in .lircrc.

irexec should run as a service. The contrib directory contains a .desktop file which could be dropped in ~/.local/autostart. Doing so creates a service which can be handled by regular desktop tools on all major desktops. If you need to run run restricted commands such as powering off the machine, you can use sudo to allow regular users to run specific commands. See the Configuration Guide in the html documentation.

SEE ALSO

The documentation for lirc is maintained as html pages. They are located under html/ in the documentation directory.