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

fix: make yaml output pass ansible-lint #160

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

gardar
Copy link
Contributor

@gardar gardar commented Apr 26, 2024

  • Adds yaml boundary marker --- to the header of the file.
  • Increases indentation level on list items.

fixes: #91
fixes: #152

@gardar gardar force-pushed the pretty-changelog-yaml branch 2 times, most recently from b21f35d to 8aef2d8 Compare April 26, 2024 17:48
@gardar
Copy link
Contributor Author

gardar commented Apr 26, 2024

Not sure if what the nox linter is complaining about is related to my changes.

src/antsibull_changelog/changes.py:702: error: Call to abstract method "sort" of "ChangesBase" with trivial body via super() is unsafe  [safe-super]

@felixfontein
Copy link
Collaborator

Thanks for your contribution! Please make this behavior configurable. It should not be the default IMO.

(#161 fixes the mypy linting error; it is due to a newer version of mypy.)

@gardar
Copy link
Contributor Author

gardar commented Apr 26, 2024

Ok sure, although I don't see what harm it could do to have it as the default format.
How do you propose I make it configurable? Do you want a new parameter?

Signed-off-by: gardar <gardar@users.noreply.github.com>
Signed-off-by: gardar <gardar@users.noreply.github.com>
@felixfontein
Copy link
Collaborator

Ok sure, although I don't see what harm it could do to have it as the default format.

This causes huge changes in changelogs/changelog.yaml in many collections.

How do you propose I make it configurable? Do you want a new parameter?

I would add a setting to changelogs/config.yaml.

Signed-off-by: gardar <gardar@users.noreply.github.com>
Signed-off-by: gardar <gardar@users.noreply.github.com>
@gardar
Copy link
Contributor Author

gardar commented May 23, 2024

I would add a setting to changelogs/config.yaml.

@felixfontein this should be all ready now.

Signed-off-by: gardar <gardar@users.noreply.github.com>
Signed-off-by: gardar <gardar@users.noreply.github.com>
changelogs/fragments/160-changelog-nice-yaml.yml Outdated Show resolved Hide resolved
docs/changelog-configuration.md Outdated Show resolved Hide resolved
docs/changelog-configuration.md Outdated Show resolved Hide resolved
gardar and others added 2 commits May 24, 2024 20:28
Co-authored-by: Felix Fontein <felix@fontein.de>
Signed-off-by: gardar <gardar@users.noreply.github.com>
@gardar gardar requested a review from felixfontein May 24, 2024 20:32
Copy link
Collaborator

@felixfontein felixfontein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

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