mirror of
https://github.com/coder/coder.git
synced 2026-09-22 05:05:20 +08:00
* Revert "revert: Makefile buff-ification (#3700) (#3848)"
This reverts commit e490bdd531.
* fix: fix slim targets in makefile
* fix: don't clobber slim binaries, make sure they're in the correct location
29 lines
534 B
Bash
Executable File
29 lines
534 B
Bash
Executable File
#!/bin/bash
|
|
|
|
set -euo pipefail
|
|
# shellcheck source=scripts/lib.sh
|
|
source "$(dirname "${BASH_SOURCE[0]}")/lib.sh"
|
|
cdroot
|
|
|
|
FILES="$(git ls-files --other --modified --exclude-standard)"
|
|
if [[ "$FILES" != "" ]]; then
|
|
mapfile -t files <<<"$FILES"
|
|
|
|
log
|
|
log "The following files contain unstaged changes:"
|
|
log
|
|
for file in "${files[@]}"; do
|
|
log " - $file"
|
|
done
|
|
|
|
log
|
|
log "These are the changes:"
|
|
log
|
|
for file in "${files[@]}"; do
|
|
git --no-pager diff "$file" 1>&2
|
|
done
|
|
|
|
log
|
|
error "Unstaged changes, see above for details."
|
|
fi
|