Skip to content

Commit b0fde49

Browse files
chezoujazzido
authored andcommitted
Enforce checkout with LF
Windows CI fails when parsing CSV with line breaks within a cell. This is due to the difference of line endings between CRLF vs LF, and test CSV parser implementation. To mitigate this issue, tweak Windows CI to enforce git checkout with LF.
1 parent 3c2af18 commit b0fde49

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

.github/workflows/tests-windows.yml

+8-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Java CI
1+
name: Java CI (Windows)
22

33
on: [push]
44

@@ -7,9 +7,14 @@ jobs:
77
runs-on: windows-latest
88

99
steps:
10-
- uses: actions/checkout@v2
10+
# https://github.com/actions/checkout/issues/135#issuecomment-602171132
11+
- name: Set git to use LF
12+
run: |
13+
git config --global core.autocrlf false
14+
git config --global core.eol lf
15+
- uses: actions/checkout@v3
1116
- name: Set up JDK 11
12-
uses: actions/setup-java@v2
17+
uses: actions/setup-java@v3
1318
with:
1419
java-version: '11'
1520
distribution: 'adopt'

.github/workflows/tests.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ jobs:
77
runs-on: ubuntu-latest
88

99
steps:
10-
- uses: actions/checkout@v2
10+
- uses: actions/checkout@v3
1111
- name: Set up JDK 11
12-
uses: actions/setup-java@v2
12+
uses: actions/setup-java@v3
1313
with:
1414
java-version: '11'
1515
distribution: 'adopt'

0 commit comments

Comments
 (0)