Use crontab to periodically execute Python scripts on Mac

Source: Internet
Author: User

This month, I bought a book, "Linux system command and Shell Scripting Practice Guide", saw a recurring task cron. Suddenly, there is an idea: is there such a mechanism on Mac?

Add oneself also in the second half of 15 also learned a bit of Python script, Haha, immediately produced the idea of "Mac using crontab periodically execute Python script", have to say

Network is to force, incredibly still really have, suddenly feel the endless wow.

1. Crontab-e to edit and customize your own tasks

For information on how to define your own tasks, we can refer to here

2. Edit the Python script:

3. The effect is as follows:

Well, the basic effect of the operation is this, of course, you can diy a lot of things, such as the periodic deletion of files Wow, Periodic grab pack Wow, periodic app packaging Wow, haha, of course there are other,

After all, the script you can write casually, or you do not have to use a Python script, in fact, there are tasks can be created. Where does the path to the test.py script in this case be placed? I leave a suspense here, you want to go (very simple)

Use crontab to periodically execute Python scripts on Mac

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.