Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
21 views

I am trying to create a Launch Daemon that launches whenever I log in. I know that launch agents are better suited for this job, but I want to accomplish it with a launch daemon instead because It's ...
tandem1032's user avatar
0 votes
0 answers
131 views

I'm creating a launch agent using the following method: @implementation AppDelegate { SMAppService *agentService; } - (void)applicationDidFinishLaunching:(NSNotification *)aNotification { ...
Bri Bri's user avatar
  • 1,992
0 votes
0 answers
58 views

I have a launchagent that I've been using for well over 10 years. Once a week it cleans up my desktop, moving any files it finds to a "Desktop_Archive" folder. Unfortunately, while the ...
Mike Heinz's user avatar
  • 1,835
1 vote
1 answer
104 views

I have run out of things to look for or don't know where to look anymore. I have a perl script that checks a particular website to see if it has changed, and throws an alert one way or another. ...
Harry_'s user avatar
  • 65
0 votes
1 answer
125 views

I am facing an issue with a bash script run by a LaunchDaemon on macOS, which is supposed to change the permissions of the Google Chrome application at specific times. The script runs correctly when ...
Atrox's user avatar
  • 75
1 vote
0 answers
56 views

I am new to this group. Hopefully someone can provide some guidance to solve my issue... I am attempting to schedule the running of my python program on my Mac using launchd. I have hit a roadblock ...
GascanTX's user avatar
0 votes
1 answer
66 views

I'm writing a bash script that enables and disables sleeping on my MacBook based on whether my headphones are connected by bluetooth or not, so I can close the lid and listen to music without the ...
Klumpy7's user avatar
  • 123
2 votes
0 answers
60 views

I have this application that is divided in 3 parts. A server that handles all the networking code A agent that handles all System related code A manager (NSApplication) to interact with the other two ...
Gama's user avatar
  • 384
0 votes
0 answers
109 views

I would like to achieve simple thing but struggling for the whole day. :( I made a simple macOS app. In AppDelegate, applicationDidFinishLaunching, I would like to execute a helper program which is ...
Kyung Lee's user avatar
0 votes
0 answers
387 views

I have a script that I would like to run every day at 4 AM. It downloads data to my user folder, fits some models, and saves files within my user directory. The script is a shell script, with one ...
Ike348's user avatar
  • 173
-1 votes
1 answer
57 views

The script sorts the download folder into folders with date. #!/bin/bash eDate=$(date +%s) #Epochal date cDate=$(date +%Y-%m-%d) ...
Atalantia's user avatar
0 votes
1 answer
66 views

Updated; I found the path to npx using type npx I would like to run a TypeScript script from a launchd. I'm successfully running the script directly using /usr/local/bin/npx ts-node /path/to/script.ts ...
Ben Robinson's user avatar
  • 1,875
1 vote
1 answer
3k views

There's a plist in /System/Library/LaunchAgents/com.openssh.ssh-agent.plist. I've spent a couple hours trying to get it to start at boot/login, but I have had no luck yet. Most of my time has been ...
devoutsalsa's user avatar
  • 1,200
0 votes
0 answers
232 views

I'm not a programmer, so I went to solve my problem in ChatGPT. The task is this: create a script that will automatically create a screenshot of the entire screen on MacOS every 2 minutes, save them ...
NewbieCoder's user avatar
1 vote
0 answers
249 views

I am currently writing an agent for endpoint security. I cannot connect the application and the xpc service. I start the plist with launchctl and then open the application, but it does not connect and ...
Bugra Karabudak's user avatar
-1 votes
1 answer
314 views

first and foremost: I'm new to macOS scripting and rely heavily on the internet to get things done. I searched for a while but couldn't find a solution, so I'm asking here. Please tell me if this isn'...
meatballbeam's user avatar
0 votes
1 answer
182 views

I am trying to schedule two zsh commands every 10 seconds The plist <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" &...
David Harris's user avatar
0 votes
2 answers
660 views

I have an rsync2server script that works to completion when run from zsh. Now I'm trying to make it run at night when my MacBook Air m2 2023 Ventura is sleeping. First I created a plist to execute the ...
pferrel's user avatar
  • 5,700
1 vote
0 answers
166 views

I know this has asked before, but I have not yet found an answer that has actually helped me. What I'm trying to do is write a launchd daemon in Swift, that will catch the shutdown notification and ...
Gregorio Litenstein's user avatar
0 votes
1 answer
102 views

I wanted to launch a GUI Application as a User Agent in Macos, but I m not sure about the right way of doing it. I m aware of 2 ways and wanted to know which should be used and why? Using the Unix ...
Vipul Gupta's user avatar
-1 votes
1 answer
562 views

I put the plist file in /Library/LaunchDaemons directory, chown to root and run sudo launchctl load -w /Library/LaunchDaemons/homebrew.mxcl.nginx.plist to enable and load it. zyl@imac:~% ls -l /...
user2256177's user avatar
1 vote
0 answers
231 views

I am using the Jenkins Swarm Plug-in v.3.24 to run my 2020 M1 mac mini with macOS Ventura 13.3.1 as a Jenkins agent. The goal is to use Jenkins to schedule and execute iOS build scripts on that mac. ...
quaini's user avatar
  • 11
0 votes
0 answers
294 views

On macOS I have several servers set up to run via a user account called "server". From my main user account, I can start them manually with the following commands, one after the other, and ...
Cirrocumulus's user avatar
0 votes
0 answers
163 views

From an app written in C++, how can I tell that my launch daemon is currently running? And preferably how to get its PID? For instance, if I run the following in the terminal: launchctl list com....
c00000fd's user avatar
  • 22.8k
0 votes
0 answers
71 views

I am currently writing an automation script for mac that takes control of time machine to run the backup at night. the script is wotking when running from a terminal, interaction as expected with time ...
DLaq's user avatar
  • 1
1 vote
1 answer
153 views

I found these instructions for automating Slack status based on the connected wi-fi. The post is quite old and it is not working for me on MacOS Ventura. To be honest, I don't even know how to debug ...
fusio's user avatar
  • 3,675
2 votes
1 answer
2k views

I'm writing an installer for my launch daemon, and for a launch agent, that will run in every logged in user session on macOS. The installer will be running as an admin, and thus I can install and ...
c00000fd's user avatar
  • 22.8k
-1 votes
2 answers
171 views

I have a launch daemon (written in C++) that runs on macOS. Is there a way to tell if the operating system is currently restarting? (Or the moment after the user hit Apple Logo -> Restart and the ...
c00000fd's user avatar
  • 22.8k
1 vote
0 answers
174 views

To learn about macOS services (daemons and agents), I have a sample GUI app which counts every 10 sec in the background and displays some UI. In AppDelegate.swift class AppDelegate: NSObject, ...
NightFuryLxD's user avatar
0 votes
0 answers
2k views

I've coded my launch daemon and a launch agent for macOS. When the app is installed, I need to run both the daemon and the agent. I place the .plist for the deamon into /Library/LaunchDaemons and then ...
c00000fd's user avatar
  • 22.8k
0 votes
1 answer
4k views

There are red dots, rather than green dots, next to "Active Instance" in the preference pane. Image here. When I click "Start MySQL Server" the lights flash green very briefly ...
S. Forman's user avatar
1 vote
1 answer
2k views

I would like my logs to show up when I do something like this log show --debug --info | grep "Myapp" I am currently doing something like this in launchd which writes to a flat file. <key&...
James Franco's user avatar
  • 4,786
3 votes
1 answer
1k views

I have a number of launch agents I've written over the years to automate some simple tasks, like rsyncing my music and photos from my laptop to my NAS. Recently I've noticed that they have stopped ...
Mike Heinz's user avatar
  • 1,835
0 votes
0 answers
287 views

I wrote a script to take a picture with my webcam. I want it to run everytime I unlock my mac, so I created a com.example.selfie.plist file in ~/Library/LaunchAgents/. The sh script is working well ...
taccle's user avatar
  • 1
2 votes
1 answer
2k views

I have an app service I want to start at system startup with a plist file: <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"&...
Sean's user avatar
  • 2,129
0 votes
1 answer
278 views

I was hoping someone could point out where I might be going wrong with a launchctl script I'm trying to write and launch. The intention is to run a python script I've managed to get working, everyday ...
JaceExton's user avatar
1 vote
1 answer
3k views

I have a launch daemon that I just can't get to work. It's supposed to run a script every day at 3 AM. The script works and I can run it manually without sudo. See below for the launch daemon (com....
nick.sullivan510's user avatar
0 votes
1 answer
475 views

Working on my first macOS Launch Agent using XPC. I need the process that is delivering the service to be started by launchd and to then stay running until the client process that made the initial ...
chemFour's user avatar
  • 319
1 vote
1 answer
498 views

I'm following a tutorial to create a launchd job that runs a simple hello-world script. The instructions require the creation of a plist file and suggest the following filename: com.demo.daemon.plist ...
Andrew Parmar's user avatar
2 votes
0 answers
770 views

I have created a Worker Service with .Net 6, I have published it via folder profile for Mac OS, Now in Windows I can create a service using SC CREATE, how do I achieve the same on Mac OS. I have tried ...
Mehroz Irshad's user avatar
2 votes
0 answers
151 views

I have an authentication app (authApp) that runs on Mac. AuthApp lets you log in to the Mac. It runs in place of the default login screen. I have added a new button in authApp and I want that button ...
RituV's user avatar
  • 65
0 votes
1 answer
167 views

After upgrading to macOS 12.4 our Golang app which runs as a service on macOS is unable to read files in the user's home directory. Even when the file is readable for all the users. The service runs ...
adnan kamili's user avatar
  • 9,555
0 votes
0 answers
174 views

I have started scheduling a couple scripts in Python using launchd. All my imports are from the root directory, though, so unless I want to mess with sys.path (which feels like poor practice) I need ...
Oliver R's user avatar
  • 195
1 vote
1 answer
654 views

The current macOS 13 beta has a feature in which it displays all application-installed Login Items in a System Preferences panel, including LaunchDaemons. My app has a LaunchDaemon written in Go ...
fsctl's user avatar
  • 343
0 votes
1 answer
461 views

I am trying to automatically run a python script every 3 days. What I am trying to accomplish is that the script is scheduled for every 3 days and if at that time the computer is offline, the job ...
user18765140's user avatar
1 vote
1 answer
1k views

I am playing around with a very simple plist script which I want to execute at start-up and should create a simple text document after execution. The file is as follows: <?xml version="1.0&...
Alan A's user avatar
  • 2,551
2 votes
1 answer
2k views

I am attempting to port a C# Windows application to macOS 12 Monterey for the first time. One of its features was setting up automatic start-up, which in there was done through Windows registry. I ...
pbnn's user avatar
  • 33
0 votes
0 answers
137 views

I have a bash script like so: #!/bin/bash cd / pwd ls cd Users pwd ls cd robl pwd ls cd Documents pwd ls When I run it manually via ~/bin/script.sh, it works as expected. However, when I make a ....
robl's user avatar
  • 124
1 vote
3 answers
825 views

I use launchd to configure a service to write logs to the file. This is the launchd config. <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//...
tural's user avatar
  • 320
0 votes
1 answer
363 views

So how do you run a PHP script once every 1 minute using a plist file with launchd (launchctl) in MacOS? This was a question I had that took forever to find the answer to, but I did eventually! I'm ...
Juno Sprite's user avatar

1
2 3 4 5
13