From 0f586d58083b4cfe0ae1e6e91696fd7dd972431a Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Sun, 1 Jan 2017 18:32:57 -0800 Subject: [PATCH] Convert some files back into DOS line endings after updating copyright --- build-scripts/update-copyright.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/build-scripts/update-copyright.sh b/build-scripts/update-copyright.sh index 34864bc91cd08..84d563b5d4f6c 100755 --- a/build-scripts/update-copyright.sh +++ b/build-scripts/update-copyright.sh @@ -2,8 +2,15 @@ find . -type f -exec grep -Il "Copyright" {} \; \ | grep -v \.hg \ -| while read i; \ +| while read $file; \ do \ - LC_ALL=C sed -ie "s/\(.*Copyright.*\)[0-9]\{4\}\( *Sam Lantinga\)/\1`date +%Y`\2/" "$i"; \ - rm "${i}e"; \ + LC_ALL=C sed -ie "s/\(.*Copyright.*\)[0-9]\{4\}\( *Sam Lantinga\)/\1`date +%Y`\2/" "$file"; \ + rm "${file}e"; \ +done + +for file in COPYING.txt VisualC-WinRT/SDL2-WinRT.nuspec VisualC-WinRT/SDL2main-WinRT-NonXAML.nuspec src/main/windows/version.rc visualtest/COPYING.txt +do if [ -f "$file" ]; then + sed 's/$'"/`echo \\\r`/" $file > $file.new + mv $file.new $file + fi done