Skip to content

fix(init): enable yamllint indentation rule#251

Merged
zeitlinger merged 1 commit intomainfrom
codex/yamllint-indent
Apr 28, 2026
Merged

fix(init): enable yamllint indentation rule#251
zeitlinger merged 1 commit intomainfrom
codex/yamllint-indent

Conversation

@zeitlinger
Copy link
Copy Markdown
Member

Summary

Converges generated .github/config/.yamllint.yml on indentation: enable instead of the legacy nested spaces: 2 shape.

The generator test now asserts the exact generated config so this does not drift back to ad hoc variants.

Validation

  • cargo test generate_yamllint_config_writes_file
  • FLINT_CASES=general/init-rust cargo test cases
  • FLINT_CASES=ryl mise exec -- cargo test cases
  • mise run lint:fix
  • mise run lint
  • mise exec -- cargo test --bins -- --skip registry::tests::all_registry_binaries_found

Note: full cargo test --bins is blocked in this environment by missing dotnet-format.

Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
@zeitlinger zeitlinger marked this pull request as ready for review April 28, 2026 16:56
@zeitlinger zeitlinger requested a review from a team as a code owner April 28, 2026 16:56
Copilot AI review requested due to automatic review settings April 28, 2026 16:56
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the generated yamllint configuration to use the canonical indentation: enable rule form (instead of the legacy nested spaces: 2 form) and hardens the generator test to prevent future drift in the generated .github/config/.yamllint.yml.

Changes:

  • Update .yamllint.yml fixtures to use indentation: enable.
  • Update the init generator (generate_yamllint_config) to emit indentation: enable.
  • Strengthen the generator test to assert the full generated file content exactly.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/init/config_files.rs Changes yamllint config generation to emit indentation: enable.
src/init/tests.rs Updates test to assert exact .yamllint.yml output, preventing config drift.
.github/config/.yamllint.yml Aligns repo yamllint config with indentation: enable.
tests/cases/general/init-rust/test.toml Updates init-rust golden output to match new generated yamllint config.
tests/cases/ryl/clean/files/.github/config/.yamllint.yml Updates ryl clean fixture to the new indentation rule shape.
tests/cases/ryl/failure/files/.github/config/.yamllint.yml Updates ryl failure fixture to the new indentation rule shape.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@zeitlinger zeitlinger merged commit 7d41ecb into main Apr 28, 2026
18 checks passed
@zeitlinger zeitlinger deleted the codex/yamllint-indent branch April 28, 2026 18:01
This was referenced May 8, 2026
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.

3 participants