10
0
mirror of https://github.com/QuantumPackage/qp2.git synced 2024-12-23 21:03:49 +01:00
QuantumPackage/scripts/remove_trailing_spaces

17 lines
209 B
Plaintext
Raw Normal View History

2019-01-25 11:39:31 +01:00
#!/bin/bash
#
# Removes white spaces at the end of lines.
#
# Usage:
#
# remove_trailing_spaces FILE
#
if [[ -n $1 ]] ; then
exec sed --in-place 's| *$||' $1
else
>&2 echo "Usage: $0 FILE"
exit 1
fi