Chris
Chris

Reputation: 1

How do I autostart a script in terminal mode based on keyboard activity?

I have a box running Debian command line only, and attached to a monitor. It is always on, displaying its terminal screen on my mini LCD monitor. I want a screensaver for the terminal, and seem to have found one (cmatrix, aafire). I just dont know how to launch the screensaver after 60 minutes of no keyboard input on the local monitor.

How do I launch a specific script or program on the local terminal after say 60 minutes of keyboard inactivity?

Upvotes: 0

Views: 736

Answers (1)

Martin
Martin

Reputation: 41

Have a look at this thread https://superuser.com/questions/638357/execute-a-command-if-linux-is-idle-for-5-minutes

You could just use xprintidle to queries the X server for the user's idle time.

Upvotes: 1

Related Questions