Missing set Safety Options #23
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
#!/bin/bash
No error handling
Improvement: Add at top:
set -euo pipefail # Exit on error, undefined vars, pipe failures
OR for more control:
set -o errexit
set -o nounset
set -o pipefail
Note: May need -e off if you want graceful degradation.