Remove trailing space characters in the formatting script

This commit is contained in:
Aaron Franke
2020-06-17 14:53:10 -04:00
parent d3317cc91d
commit 35d44b5d85
36 changed files with 53 additions and 51 deletions

View File

@@ -1,4 +1,4 @@
Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur.
Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. \
Copyright (c) 2014-2020 Godot Engine contributors.
Permission is hereby granted, free of charge, to any person obtaining

View File

@@ -17,6 +17,8 @@ while IFS= read -rd '' f; do
sed -i '1s/^\xEF\xBB\xBF//' "$f"
# Ensures that files end with newline characters.
tail -c1 < "$f" | read -r _ || echo >> "$f";
# Remove trailing space characters.
sed -z -i 's/\x20\x0A/\x0A/g' "$f"
done
git diff > patch.patch