You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If line is used to get the line number of a match, the value is incorrectly offset by the number of lines at the start of the document that are trivia before the first key.
Version of yq: 4.42.1
Operating system: Ubuntu 22.04.2
Installed via: Binary from GitHub releases
Input Yaml
---
foo:
bar: 42
Command
The command you ran:
yq ".foo.bar | line"
Actual behavior
2
Expected behavior
4
The text was updated successfully, but these errors were encountered:
Describe the bug
If
line
is used to get the line number of a match, the value is incorrectly offset by the number of lines at the start of the document that are trivia before the first key.Version of yq: 4.42.1
Operating system: Ubuntu 22.04.2
Installed via: Binary from GitHub releases
Input Yaml
Command
The command you ran:
Actual behavior
2
Expected behavior
4
The text was updated successfully, but these errors were encountered: