Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # ------------------Bucklespring---------------
- if ! pgrep -x "buckle" > /dev/null; then
- echo "Bucklespring started on process: " && buckle &
- else
- echo "Bucklespring is already running."
- fi
- # Function to kill all processes containing "buckle"
- kill_buckle_processes() {
- pkill -f "buckle"
- }
- # Trap function to call kill_buckle_processes when the shell exits
- trap 'kill_buckle_processes' EXIT
Advertisement
Add Comment
Please, Sign In to add comment