I have a fairly light script that I want to run periodically in the background every 5 hours or so. The script runs through a few different websites, scans them for new material, and either grabs .mp3 files from them or likes songs on youtube based on their content. There are a few things I want to achieve with this program that I am unsure of how to attain:
- Have the program run every 5 hours -- I'm not to familiar with system-level timing operations.
- Have the program efficiently run in the background -- I want these 'updates' to occur without the user knowing.
- Have the program activate on startup -- I know how I would set this up as a user, but I'm not sure how to add such a configuration to the python file, if that's even possible. Keep in mind that this is going to be a simple .py script -- I'm not compiling it into an executable.
The program is designed mainly with OSX and other Unix based systems in mind. Any advice on achieving some of these goals?