| 1 | #!/usr/bin/envscip-shell filesystem . . `/usr/bin/env`. bash |
| 2 | |
| 3 | set -euo pipefail |
| 4 | |
| 5 | modified_lines=$(gitscip-shell system . . git. status --short -uno | wcscip-shell system . . wc. -l) |
| 6 | (( modified_lines == 0 )) && exit 0 |
| 7 | |
| 8 | echoscip-shell system . . echo. >&2 |
| 9 | echoscip-shell system . . echo. >&2 "ERROR: Style changes detected" |
| 10 | echoscip-shell system . . echo. >&2 |
| 11 | |
| 12 | gitscip-shell system . . git. diff |
| 13 | |
| 14 | echoscip-shell system . . echo. >&2 |
| 15 | echoscip-shell system . . echo. >&2 "ERROR: Squash the above changes as needed" |
| 16 | echoscip-shell system . . echo. >&2 |
| 17 | |
| 18 | exit 1 |