timeout — Send a signal to a program after a certain time
timeout [-s signal] seconds program [args]
timeout executes a program (with arguments args) and sends a signal to it after a certain amount of seconds.
Signal to send to the spawned process. This can be a numerical or symbolic ID. This defaults to TERM.
Execute "pap foo.ps" and send a SIGTERM if pap doesn't return after 10 seconds.
Spawn a shell and send a hangup signal after one minute.
Execute a program and KILL it if it doesn't quit after 10 seconds.