Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
crypto-news-service/cron.py
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
13 lines (9 sloc)
347 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create a cron job that periodically sends emails | |
from crontab import CronTab | |
cron = CronTab(tab="""* * * * * command""") | |
once_a_day_job = cron.new(command='python emailClients.py 1 ') | |
job.minute.every(1) | |
job.enable(True) | |
cron.write() | |
for result in cron.run_scheduler(): | |
print("This was printed to stdout by the process.") |