rashmisajjan / django-cron

Automatically exported from code.google.com/p/django-cron
MIT License
0 stars 0 forks source link

How to Make the cron Job run in windows ? #2

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
I run django project in windows, how can I setup the project to run the
cron job? Thanks.

Original issue reported on code.google.com by fangzhou...@gmail.com on 8 Jun 2008 at 3:07

GoogleCodeExporter commented 8 years ago
You need to;
1) add cron to your INSTALLED_APPS
2) run manage.py syncdb
3) create a file called cron.py in whatever other django application you wish 
to run
the Job in
4)edit the cron.py to that you import the Cron class, and create a class of 
your own
that looks like

MyCronClass(Cron):
    run_every = 2

    def job(self):
        # Code to do whatever you want here

        return True

Original comment by digitalx...@gmail.com on 8 Jun 2008 at 3:45

GoogleCodeExporter commented 8 years ago

Original comment by digitalx...@gmail.com on 8 Jun 2008 at 3:56