Skip to content

rschmukler/caffeinate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Caffeinate

A command-line app bringing caffeinate functionality to xidlehook.

Features

Triggers

Triggers are used to monitor for when caffeinate should exit (and allow xidlehook to resume).

  • Timer
  • PID-based monitoring

Quit Actions

Quit actions are used in conjunction with triggers to perform a final action before caffeinate exits.

Setup

cargo install --git https://github.com/rschmukler/caffeinate

Start xidlehook with a socket argument:

xidlehook --timer primary 60 "xset dpms force off" --socket "/tmp/xidlehook.sock"

Usage Examples

# Running indefinitely (exit with Ctrl-C)
caffeinate

# Running for an hour
caffeinate --timer 3600

# Running until a process exits, then shutdown down the machine
caffeinate --pid 1234 --quit=shutdown

About

Keeping xidlehook woke

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages