The bash -c command used bare && inside a <string>, which isn't valid XML: plutil -lint rejects the file, and launchd only loaded it because its parser is lenient. Escape the operator, and move PATH into EnvironmentVariables so the command stays short enough that an XML formatter has no reason to re-wrap it.
32 lines
950 B
Plaintext
32 lines
950 B
Plaintext
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
<plist version="1.0">
|
|
<dict>
|
|
<key>Label</key>
|
|
<string>com.user.homebrew-update</string>
|
|
<key>ProgramArguments</key>
|
|
<array>
|
|
<string>/bin/bash</string>
|
|
<string>-c</string>
|
|
<string>brew update && brew upgrade</string>
|
|
</array>
|
|
<key>EnvironmentVariables</key>
|
|
<dict>
|
|
<key>PATH</key>
|
|
<string>/opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin</string>
|
|
</dict>
|
|
<key>StartCalendarInterval</key>
|
|
<dict>
|
|
<key>Hour</key>
|
|
<integer>0</integer>
|
|
<key>Minute</key>
|
|
<integer>0</integer>
|
|
</dict>
|
|
<key>StandardErrorPath</key>
|
|
<string>/tmp/com.user.homebrew-update.err</string>
|
|
<key>StandardOutPath</key>
|
|
<string>/tmp/com.user.homebrew-update.out</string>
|
|
</dict>
|
|
</plist>
|
|
|