#!/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