plakar icon indicating copy to clipboard operation
plakar copied to clipboard

Add optional conditions to scheduler

Open paulrudy opened this issue 2 months ago • 0 comments

There may be varying conditions for which plakar backup (or other functions) would be appropriate to modify, enable, or disable.

In my case, I'm considering using plakar to backup a laptop, in which case things like battery and network become considerations for how and when the scheduler should operate.

One possible route to handle this might be adding condition parameters in the scheduler for each task. Two options for handling conditions come to mind:

  1. Task runs while its conditions are true. Task gracefully stops (or pauses?) when a condition becomes false
  2. Task runs differently depending on conditions (e.g. if plakar introduces throttling, then throttle to 100% on full battery, throttle to 20% on low battery, etc)

Some useful conditions to include:

  • network (whitelist, blacklist, etc)
  • power/battery level
  • some flag (e.g. presence or contents of a particular config file) that an external automation solution (like MacOS Shortcuts, etc) could change depending on its own conditions

I haven't experimented with it yet, but as I'm on MacOS, I've considered using Shortcuts to manage the goals in this feature request. However it would be useful to have a built-in solution.

paulrudy avatar Oct 21 '25 20:10 paulrudy