-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Labels
bugSomething isn't workingSomething isn't working
Description
1️⃣ Description
I have "valid" YAML file with not the best list indents and yamlfixer breaks it
📑 Steps to Reproduce
Steps to reproduce the behavior:
- When I have
test.ymllike this:
---
a:
b:
- 1
- 2
- 3
c:
4-
Then run that:
yamlfixer --nochange --summary --diffto my.patch test.yml -
I get such change:
--- "test.yml"
+++ "test.yml-after"
@@ -2,7 +2,7 @@
a:
b:
- - 1
+ - 1
- 2
- 3
c:2️⃣ Expected behavior
All lines with elements 1, 2 and 3 should be indented with two extra spaces like this:
---
a:
b:
- 1
- 2
- 3
c:
4
Diff should look like this:
--- "test.yml"
+++ "test.yml-after"
@@ -2,8 +2,8 @@
a:
b:
- - 1
- - 2
- - 3
+ - 1
+ - 2
+ - 3
c:
4
# ℹ️ Environment details
- OS: `openSUSE Leap 15.4`
- Python runtime: `3.10.10`
- The output of `yamlfixer --version`: `yamlfixer v0.9.15`
- Used shell: bash
# Additional context
Add any other context about the problem here.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working