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

to_entries[] is not supported #1246

Closed
SuperSandro2000 opened this issue Jun 21, 2022 · 1 comment
Closed

to_entries[] is not supported #1246

SuperSandro2000 opened this issue Jun 21, 2022 · 1 comment
Labels

Comments

@SuperSandro2000
Copy link
Contributor

SuperSandro2000 commented Jun 21, 2022

Describe the bug
A clear and concise description of what the bug is.

Note that any how to questions should be posted in the discussion board and not raised as an issue.

Version of yq: 4.25.2
Operating system: maclinux
Installed via: NixOS

Input Yaml
data1.yml:

values:
  - global.region: qa-de-1

Command

yq '.values[] | to_entries[]' data1.yml

Actual behavior

Error: Bad expression, please check expression syntax

Expected behavior

key: global.region
value: qa-de-1

Additional context
This can be worked around with yq '.values[] | to_entries | .[]' data1.yaml but it would be cool to have the alias to be jq compatible.

@mikefarah
Copy link
Owner

Fixed (finally) in 4.40.7

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

No branches or pull requests

2 participants