mirror of
https://github.com/finos/SymphonyElectron.git
synced 2025-01-03 12:47:13 -06:00
Removes launchd plist files as there no longer needed (#441)
This commit is contained in:
parent
b8626e0756
commit
0d1fe72849
@ -1,44 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
pid=$2
|
|
||||||
launchDir=~/Library/LaunchAgents/
|
|
||||||
|
|
||||||
if $1; then
|
|
||||||
if [ ! -d "$launchDir" ]; then
|
|
||||||
mkdir "$launchDir"
|
|
||||||
fi
|
|
||||||
launchctl unload ~/Library/LaunchAgents/com.symphony-search.data.plist
|
|
||||||
cat > ~/Library/LaunchAgents/com.symphony-search.data.plist << EOT
|
|
||||||
<?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.symphony-search.data.agent</string>
|
|
||||||
<key>ProgramArguments</key>
|
|
||||||
<array>
|
|
||||||
<string>/bin/sh</string>
|
|
||||||
<string>scriptPath</string>
|
|
||||||
<string>false</string>
|
|
||||||
<string>SymphonyPID</string>
|
|
||||||
</array>
|
|
||||||
<key>RunAtLoad</key>
|
|
||||||
<false/>
|
|
||||||
<key>StartInterval</key>
|
|
||||||
<integer>60</integer>
|
|
||||||
<key>StandardOutPath</key>
|
|
||||||
<string>/dev/null</string>
|
|
||||||
<key>StandardErrorPath</key>
|
|
||||||
<string>/dev/null</string>
|
|
||||||
</dict>
|
|
||||||
</plist>
|
|
||||||
EOT
|
|
||||||
launchctl load ~/Library/LaunchAgents/com.symphony-search.data.plist
|
|
||||||
elif ps -p $pid > /dev/null
|
|
||||||
then
|
|
||||||
echo true
|
|
||||||
else
|
|
||||||
echo false
|
|
||||||
rm -rf dataPath
|
|
||||||
launchctl unload ~/Library/LaunchAgents/com.symphony-search.data.plist
|
|
||||||
rm -rf ~/Library/LaunchAgents/com.symphony-search.data.plist
|
|
||||||
fi
|
|
@ -1,35 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
launchDir=~/Library/LaunchAgents/
|
|
||||||
|
|
||||||
if $1; then
|
|
||||||
if [ ! -d "$launchDir" ]; then
|
|
||||||
mkdir "$launchDir"
|
|
||||||
fi
|
|
||||||
cat > ~/Library/LaunchAgents/com.symphony-search.clear.plist << EOT
|
|
||||||
<?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.symphony-search.clear.daemon</string>
|
|
||||||
<key>ProgramArguments</key>
|
|
||||||
<array>
|
|
||||||
<string>/bin/sh</string>
|
|
||||||
<string>scriptPath</string>
|
|
||||||
<string>false</string>
|
|
||||||
</array>
|
|
||||||
<key>RunAtLoad</key>
|
|
||||||
<true/>
|
|
||||||
<key>KeepAlive</key>
|
|
||||||
<false/>
|
|
||||||
<key>StandardOutPath</key>
|
|
||||||
<string>/dev/null</string>
|
|
||||||
<key>StandardErrorPath</key>
|
|
||||||
<string>/dev/null</string>
|
|
||||||
</dict>
|
|
||||||
</plist>
|
|
||||||
EOT
|
|
||||||
else
|
|
||||||
rm -rf dataPath
|
|
||||||
fi
|
|
Loading…
Reference in New Issue
Block a user