Added warning at the top of the generated typescript file that it is generated#4
Conversation
irahopkinson
left a comment
There was a problem hiding this comment.
@irahopkinson reviewed 3 of 3 files at r1, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @lyonsil and @tjcouch-sil)
src/generate-markers-map.ts line 129 at r1 (raw file):
// Figure out the line endings and add the generated warning at the top const lineEnding = markersMapModelContent.includes('\r\n') ? '\r\n' : '\n';
Any file that is committed in any of our repos should all have line endings of \n so that they work on any OS without causing odd repo conflicts. Typically even on Windows we should checkout as \n also since Windows copes fine with that. These generated files are committed aren't they?
tjcouch-sil
left a comment
There was a problem hiding this comment.
Reviewable status: 3 of 4 files reviewed, 1 unresolved discussion (waiting on @irahopkinson and @lyonsil)
src/generate-markers-map.ts line 129 at r1 (raw file):
Previously, irahopkinson (Ira Hopkinson) wrote…
Any file that is committed in any of our repos should all have line endings of
\nso that they work on any OS without causing odd repo conflicts. Typically even on Windows we should checkout as\nalso since Windows copes fine with that. These generated files are committed aren't they?
There is a lot to say about this topic, but here are the biggest things I think of around this topic:
- We didn't have a
.gitattributesin this repo, so the files were CRLF on Windows and LF otherwise iirc - I just added a
.gitattributesdictating the files in this repo should be LF everywhere assuming someone hasn't set their git settings to force using CRLF - The source file in question is in this repo, but the file generated is not committed to this repo and is not necessarily only to be placed in our repos. I thought there were enough variables to warrant keeping it simple and following whatever line endings the file already has. I'd rather be consistent than accidentally use two different kinds of line endings in the same file
- It's not really that important
irahopkinson
left a comment
There was a problem hiding this comment.
@irahopkinson reviewed 1 of 1 files at r2, all commit messages.
Reviewable status:complete! all files reviewed, all discussions resolved (waiting on @lyonsil)
This change is