diff --git a/src/tools/shhelpers/sort_file_content.sh b/src/tools/shhelpers/sort_file_content.sh new file mode 100644 index 00000000..2c9c9907 --- /dev/null +++ b/src/tools/shhelpers/sort_file_content.sh @@ -0,0 +1,6 @@ +#!/bin/sh +# +# That script sort the content of all files in the current directory +# +ls | grep -v .sort | while read file; do sort "$file" > "$file".sort; done +for file in *.sort; do mv "$file" "${file%%.sort}"; done