Closed Benehiko closed 6 days ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 61.42%. Comparing base (
0340921
) to head (c56f4a1
). Report is 2 commits behind head on master.
I think with this change, we may be able to get rid of this part in our GHA workflow as well; https://github.com/docker/cli/blob/e2361a5ca888509f1560e60a4810597a31750266/.github/workflows/test.yml#L52-L57
If that's correct, you can remove it as part of this PR as well (can be a separate commit) /cc @crazy-max
- What I did
On Windows machines users' might install git using the default "Checkout Windows-style, commit Unix-style line endings".![image](https://github.com/docker/cli/assets/18033717/1fe6f031-ccfa-4981-8c87-5bd26e4daea7)
Or
This will prevent the user from building the CLI due to bash scripts inside the
scripts/*
directory to automatically be perceived with theCRLF
line ending. The error is ambiguous as to suggest a file is missing - however, it is due to bash scripts having incorrect line endings.- How I did it
Added
* text=auto eol=lf
to.gitattributes
to force git to by default treat files in the repository with thelf
line ending.- How to verify it
Checkout the repository on Windows and with
git config --global core.autocrlf true
then open any of the script files in an editor, the editor should tell you the line endings areLF
. You should also be able to see inside WSL, runningfile scripts/build/binary
should print... ASCII text executable
.If there's something about it containing
CRLF
then it means it's incorrect.- Description for the changelog
- A picture of a cute animal (not mandatory but encouraged)