-
-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
does not work when called from a launchagent #58
Comments
damn, it sure was hard to get the back ticks to show up in the comment field |
Could you show the whole launch agent and script (if using a script). |
AGENT:
SCRIPT: #!/bin/bash doit=``/usr/local/bin/dockutil --add /Users/$USER/Downloads --display folder --section others exit 0 |
Yeah I don't understand why the backticks would make a difference unless $USER isn't set except in subshells, but that seems odd. You could log $USER or the whole command. And turn on verbose and log the output of dockutil. Another workaround would be to use ~/Downloads. Kyle Sent from Mobile
|
tried all that, logging Its working with the backticks so i'll go with that. |
This is a shell script issue and backticks or the equivalent are needed if executed this way. Closing this while doing housekeeping of issues. |
I feel like I used dockutil in agents in the 10.9 days. Went to use from an agent with 2.0.2 and 10.11 and could not get it to work. Upgraded to 2.0.3 still not working. Tried umpteen variations of how to identify the currently logged in user in the script, never could get it to work. During troubleshooting i figured out i could get the dockutil statement to work in a LaunchAgent if i assigned the statement to a variable
this does not work
/usr/local/bin/dockutil --add /Users/$USER/Downloads --display folder --section others
for reasons i don't understand this does work
doit=
/usr/local/bin/dockutil --add /Users/$USER/Downloads --display folder --section others
The text was updated successfully, but these errors were encountered: