Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add .gitattributes to enforce LF line endings #899

Merged
merged 1 commit into from
Oct 28, 2024

Conversation

geographika
Copy link
Contributor

@geographika geographika commented Oct 26, 2024

As noted in #667 building on Windows or using the WSL having checked out https://github.com/camptocamp/docker-mapserver/ with default Windows line endings results in failed builds with a cryptic error message. Adding .gitattributes and forcing LF fixes this.

Enforcing Linux line-endings fixes this.

Build command:

docker build  --target=runner --build-arg=MAPSERVER_BRANCH=rel-8-0-2

Error:

 => [builder 2/9] RUN git clone https://github.com/mapserver/mapserver --branch=rel-8-0-2 --depth=100 /src                                                                                                  4.6s
 => [builder 3/9] COPY checkout_release /tmp                                                                                                                                                                0.1s
 => ERROR [builder 4/9] RUN cd /src     && /tmp/checkout_release rel-8-0-2                                                                                                                                  0.6s
------
 > [builder 4/9] RUN cd /src     && /tmp/checkout_release rel-8-0-2:
0.554 + cd /src
0.555 + /tmp/checkout_release rel-8-0-2
: invalid option -

@sbrunner sbrunner merged commit 3ac5c84 into camptocamp:master Oct 28, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants