On Tue, 11 Oct 2011, Polytropon wrote:

I have some users who I want to "schedule" a specific job
for which gets executed on their user account. For some
of them, it will be twice a day, for others just once a
month. It should happen at logout time.

The intended mechanism to do so is ~/.logout, the C shell's
logout script.


If the user doesn't want to wait for the script to complete for the
session to end, you could start the script with a call to "batch" or "at".

The shell documentation claims that .logout executes whenever the shell
exits, so your script should execute even if the user neglects to properly log out, however I haven't experimented with that.

Are you sure you wouldn't be better off with a cron job? Is it that you don't want the script running while the user is logged in?

Dan Feenberg
_______________________________________________
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"

Reply via email to