has-diff.sh 275 B

12345678910111213
  1. #!/bin/bash
  2. # Copyright 2019-2024 Tauri Programme within The Commons Conservancy
  3. # SPDX-License-Identifier: Apache-2.0
  4. # SPDX-License-Identifier: MIT
  5. if git diff --quiet --ignore-submodules HEAD
  6. then
  7. echo "working directory is clean"
  8. else
  9. echo "found diff"
  10. exit 1
  11. fi