From f0f40a0dbfdd835b6aaf4b54cf9cc826e7327973 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Ho=C5=99e=C5=88ovsk=C3=BD?= Date: Thu, 18 Jan 2018 12:35:40 +0100 Subject: [PATCH] Ensure that the single header is kept with LFs --- .gitattributes | 6 +++++- scripts/generateSingleHeader.py | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitattributes b/.gitattributes index a2d66d32..e29707ef 100644 --- a/.gitattributes +++ b/.gitattributes @@ -8,4 +8,8 @@ *.hpp text # Windows specific files should retain windows line-endings -*.sln text eol=crlf \ No newline at end of file +*.sln text eol=crlf + +# Keep the single include header with LFs to make sure it is uploaded, +# hashed etc with LF +single_include/*.hpp eol=lf diff --git a/scripts/generateSingleHeader.py b/scripts/generateSingleHeader.py index b1d18673..04eaf46c 100755 --- a/scripts/generateSingleHeader.py +++ b/scripts/generateSingleHeader.py @@ -46,7 +46,7 @@ def generate(v): outDir = os.path.dirname(outputPath) if not os.path.exists(outDir): os.makedirs(outDir) - out = open( outputPath, 'w' ) + out = open( outputPath, 'w', newline='\n' ) def write( line ): if globals['includeImpl'] or globals['implIfDefs'] == -1: