I use Windows Task Scheduler, and below is my current setup:
When running the task, use the following user account: (my $env:USERNAME
)
- Run whether user is logged on or not
Trigger | Details | Status |
---|---|---|
Daily | At 12:00 AM every day | Enabled |
At log on | At log on of any user | Enabled |
Action | Program/script | Arguments | Start in |
---|---|---|---|
Start a program | path\to\poetry | run counters | path\to\this\repo |
- Start only if the following network connection is available: Any connection
- Allow task to be run on demand
- Run task as soon as possible after a scheduled start is missed
- If the task fails, restart every: 1 minute
- Attempt to restart up to: 3 times
- Stop the task if it runs longer than: 1 hour
- If the running task does not end when requested, force it to stop
If the task is already running, then the following rule applies: Do not start a new instance