bash remove trailing spaces code example Example: bash remove trailing whitespace from every line # Basic syntax: awk '{$1=$1};1' your_file