Skip to content

Commit

Permalink
Merge pull request #3135 from mato/fix-installer-du
Browse files Browse the repository at this point in the history
install.sh: Fix use of "du" to always use -k
  • Loading branch information
AltGr authored Dec 12, 2017
2 parents 08e4fa4 + 146d394 commit e7743f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion shell/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ if [ -d "$OPAMROOT" ]; then
echo "Please move it away or run with --no-backup"
fi
FREE=$(df -k "$OPAMROOT" | awk 'NR>1 {print $4}')
NEEDED=$(du -s "$OPAMROOT" | awk '{print $1}')
NEEDED=$(du -sk "$OPAMROOT" | awk '{print $1}')
if ! [ $NEEDED -lt $FREE ]; then
echo "Error: not enough free space to backup. You can retry with --no-backup,"
echo "--fresh, or remove '$OPAMROOT'"
Expand Down

0 comments on commit e7743f8

Please sign in to comment.