azu / azu/launchd-ui

New Agent wizard doesn't generate functioning .plist files

Open
#4 0 comments 0 reactions 0 assignees View on GitHub
Type: Bug
Dominant language
TypeScript
Stars
141
Forks
16
PR merge metrics
No merged PRs in 30d

Description

My use case is simple: I'd like to run the program FreeFileSync once daily. The benefit of doing this with a launchd agent vs [scheduling Automator with Calendar](https://freefilesync.org/manual.php?topic=schedule-batch-jobs#macos) is that it doesn't have to occur EXACTLY at the time specified daily. I also don't really like the idea of populating the Calendar app with thousands of daily tasks. Launchd just seems much cleaner and more purpose built for this exact kind of thing.

I've been scratching my head trying to get this working all day and I think the New Agent wizard in your tool just doesn't generate useful results, at least for a noob like me trying to schedule a basic program to run. Another launchd GUI tool [launchd Package Creator](https://github.com/ryangball/launchd-package-creator) DOES generate .plist files that launch my script but it doesn't offer any options for scheduling tasks like your tool does. So I ended up making a .plist with Package Creator, then changed it's schedule using your tool and now it works!

I'm not going to pretend like I understand how everything works so I figure what might be most helpful is just a copy of the .plist file I ended up with that seems to do what I want. To the more experienced launchd .plist writer, I imagine it will pretty easy to figure out why it works and the ones your tool makes don't. I added in the "SuccessfulExit" condition too as without it, "KeepAlive" seem to restart the task every time it finishes (just using my intuition here).

My working .plist file:
```

Label
test4
Program
/usr/bin/open
ProgramArguments

/usr/bin/open
/Users/johnnywagner/Documents/FreeFileSync/nas_backup.ffs_batch

RunAtLoad

KeepAlive

SuccessfulExit


StartCalendarInterval


Minute
0
Hour
12

```

Given how simple these .plist files seem to be, adding more options and tooltips on how the Wizard works in noob friendly language would be an easy and good improvement to this tool I think. Launchd seems to be a great system, there unfortunately just isn't a robust/feature rich GUI for the average user (yet).

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at the New Agent wizard entry point and inspect the generated .plist output against the working plist included in the issue. Reproduce the FreeFileSync launchd schedule and verify that the generated agent loads, runs at the scheduled time, and does not restart unexpectedly. Done means the wizard produces a functioning plist for this use case.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, tauri, typescript
Domain
desktop
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.