Home » Questions » Computers [ Ask a new question ]

How to run a bash script outside of a terminal?

How to run a bash script outside of a terminal?

Hey All, wrote this script to confuse my girlfriend when she is using my computer. The only trouble is that if the terminal gets closed the script stops to execute. It currently executes in the background but how can I make it run in the background but not in a terminal?

Asked by: Guest | Views: 190
Total answers/comments: 2
Guest [Entry]

You could schedule it to run at a specific time with at or cron in the background.
Guest [Entry]

"I promise that no matter how much she likes you, 5 seconds is too fast an interval. Really.

nohup (and in bash disown) will allow you to detach the process from the initiating terminal."