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

Feat (#722): Enable CRLF output #723

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

timothy-mcroy
Copy link

Description of your changes

Add an output option to ensure CRLF line endings.

Fixes #722":

I have:

  • Read and followed terraform-docs' [contribution process].
  • All tests pass when I run make test.

How has this code been tested

vscode ➜ /workspaces/terraform-docs (master) $ make build && ./bin/linux-amd64/terraform-docs markdown table --output-file test-README.md --output-crlf ./examples/
==> Clean workspace
rm -rf ./bin ./coverage.out
==> Build binary for current OS/ARCH
CGO_ENABLED=0 go build -ldflags="-X github.com/terraform-docs/terraform-docs/internal/version.commit=722b659" -o ./bin/linux-amd64/terraform-docs
examples/test-README.md updated successfully
vscode ➜ /workspaces/terraform-docs (master) $ cat -v examples/test-README.md 
<!-- BEGIN_TF_DOCS -->
# This header comes from a custom Text file^M
^M
Lorem ipsum dolor sit amet, consectetur adipiscing elit,^M
sed do eiusmod tempor incididunt ut labore et dolore magna^M
aliqua. Ut enim ad minim veniam, quis nostrud exercitation^M
...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Optional CRLF line endings
1 participant