Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Convert some files back into DOS line endings after updating copyright
  • Loading branch information
slouken committed Jan 2, 2017
1 parent 49225f5 commit 0f586d5
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions build-scripts/update-copyright.sh
Expand Up @@ -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

0 comments on commit 0f586d5

Please sign in to comment.