sessiond-hooks.5

NAME

sessiond-hooks - sessiond hook file format

SYNOPSIS

  • [Hook]
  • Trigger=Lock|Idle|Sleep|Shutdown|Inactive
  • InactiveSec=<seconds> (Inactive only)
  • ExecStart=<command>
  • ExecStop=<command> (Lock|Idle|Inactive only)

DESCRIPTION

sessiond provides the ability to define hooks that are triggered by events. The “Inactive” event is unique to hooks. It allows commands to be run after a period of inactivity. It is more general than the “Idle” event, which occurs after IdleSec (see sessiond.conf(5)) seconds of inactivity.

Hooks can be specified in the configuration file using the section “[[Hook]]”. See sessiond.conf(5).

Hook files with the “.hook” suffix are read from XDG_CONFIG_HOME/sessiond/hooks.d or HOME/.config/sessiond/hooks.d.

OPTIONS

  • Trigger=

    Event type that will trigger the hook. Values are “Lock”, “Idle”, “Sleep”, “Shutdown”, “Inactive”.

  • InactiveSec=

    Seconds of inactivity after which the hook is triggered.

  • ExecStart=

    Command to execute when the hook is triggered.

  • ExecStop=

    Command to execute when the trigger event ends. For “Lock”, this is when the screen is unlocked. For “Idle” and “Inactive”, this is when activity resumes.

SEE ALSO

sessiond(1), sessiond.conf(5)