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

[FEATURE] Add option to return jq command with raw output #745

Open
dtop129 opened this issue Apr 10, 2023 · 1 comment · May be fixed by #952
Open

[FEATURE] Add option to return jq command with raw output #745

dtop129 opened this issue Apr 10, 2023 · 1 comment · May be fixed by #952
Labels
enhancement New feature or request

Comments

@dtop129
Copy link

dtop129 commented Apr 10, 2023

Description of the requested feature

For my use case, I retrieve the active window name from a JSON returned from Hyprland IPC, but since there is no option to get raw output, like with the command line option with jaq --raw-output ...., the output is "somethinginsidequotes".

I could remove the quotes by wrapping the jq call inside a replace call that removes the first and last quote characters "${replace(jq(...), "\(^\"\|\"$\)", "")}", but it would be cleaner to have this feature inside jq natively.

Proposed configuration syntax

Maybe just add alongside the normal jq function a jq_raw function, as not to break current configurations.

Additional context

No response

@dtop129 dtop129 added the enhancement New feature or request label Apr 10, 2023
@dtop129 dtop129 changed the title [FEATURE] Add to return jq command with raw output [FEATURE] Add option to return jq command with raw output Apr 10, 2023
@johnazule
Copy link

I have just come across the same thing. Would be a very useful feature, or just have an optional third argument for jq for flags such as jq("[1,2,3]", ".[]", "rc")

@RomanHargrave RomanHargrave linked a pull request Oct 21, 2023 that will close this issue
4 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants