fix: gp-stop-start

This commit is contained in:
MrRaph_
2024-06-17 19:17:25 +02:00
parent 30852e57df
commit 97033b478d

33
Utils/gp-stop-start.sh Executable file
View File

@@ -0,0 +1,33 @@
#!/bin/bash
# Required parameters:
# @raycast.schemaVersion 1
# @raycast.title GP Stop Start
# @raycast.mode silent
# @raycast.packageName MrRaph_
#
# Optional parameters:
# @raycast.icon 🌎
# @raycast.argument1 { "type": "text", "placeholder": "stop/start" }
#
# Documentation:
# @raycast.description This script stops or starts Global Protect VPN
# @raycast.author MrRaph_
# @raycast.authorURL https://git.mrraph.fr
message="Error"
case ${1} in
start)
launchctl load /Library/LaunchAgents/com.paloaltonetworks.gp.pangpa.plist
launchctl load /Library/LaunchAgents/com.paloaltonetworks.gp.pangps.plist
message="GP Started !"
;;
stop)
launchctl remove com.paloaltonetworks.gp.pangps
launchctl remove com.paloaltonetworks.gp.pangpa
message="GP Stopped !"
;;
esac
echo $message