Skip to content

Commit 2891300

Browse files
authored
Merge pull request #273 from filintod/also-remove-cr-from-file
Also remove cr from file
2 parents e15fa27 + 4ed7350 commit 2891300

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

golden/golden.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,14 @@ type helperT interface {
4040
// in the environment before running tests.
4141
//
4242
// The default value may change in a future major release.
43+
//
44+
// This does not affect the contents of the golden files themselves. And depending on the
45+
// git settings on your system (or in github action platform default like windows), the
46+
// golden files may contain CRLF line endings. You can avoid this by setting the
47+
// .gitattributes file in your repo to use LF line endings for all files, or just the golden
48+
// files, by adding the following line to your .gitattributes file:
49+
//
50+
// * text=auto eol=lf
4351
var NormalizeCRLFToLF = os.Getenv("GOTESTTOOLS_GOLDEN_NormalizeCRLFToLF") != "false"
4452

4553
// FlagUpdate returns true when the -update flag has been set.

0 commit comments

Comments
 (0)