$ jq '.y | gsub(","; "-")' <<< '{"y": "a,b"}' "a-b" $ jq '.y | gsub(","; "-")' <<< '{"x": "a"}' jq: error (at <stdin>:1): null (null) ca
how to list the Kubernetes pod which has CharDevice in it ? I could able to get the pod with CharDevice, but need to print the pod name only kubectl get pod -o
I have this JSON file: { "books":{ "book-name-1":{ "path":"management/business", "availability": true, "vars":{
I'm trying to create a massive CSV file converted from each *.json file. This snippet works until it faces the file that doesn't have the key (hobby). Original
Json looks like this: cat test.json |jq -r ".nodes[].run_data" { "id": "1234", "status": "PASSED", "penultimate_status": "PASSED", "
I want to remove , from a string in jq. Take the following example, how to remove , when outputting 1,2? $ jq -r .x <<< '{"x":"1,2"}' 1,2
I have a list of country codes like FR, IT, DE and have been trying to figure out how to use this in a select statement. I was doing something like cat stuff |
I have data.json which looks like this { "type": "AdaptiveCard", "body": [ { "type": "TextBlock", "text": "Monitoring", "wrap": true,
So for class I have to make an shell script (BASH) that uses JQ to display a superheroes secret identity and powers. It has been a pretty fun course. The script
I have massive like this: 2254003131908096 39480500160 39763833120 2296334329577472 36713833920 37747166400 2297708719112192 39830499360 41430500640 Which JQ c
I am trying to create a JSON file with jq from the result of the command "lsb_release" What i have done : if [ -x "$(command -v lsb_release)" ]; then lsb_re
I'm using jq, but I didn't manage to get a value extracted from a .json-file (I got generated by mediainfo) in my batch-script. How can I get
I have a report.json generated by a gitlab pipeline. It looks like: {"version":"14.0.4","vulnerabilities":[{"id":"64e69d1185ecc48a1943141dcb6dbd628548e725f7cef7
Using jq on JSON data ... I'm trying to select records where FromPort is 80 and CidrIp is 0.0.0.0/0 within the same element of the record. Here is the query: ca
I have this JSON: { "time": "2022-02-28T22:00:55.196Z", "severity": "INFO", "params": [ {"key": "state", "value": "pending"}, {"key"
Please help me to figure that one out... I want to get the ID where the name is - terraform-02 jq '.[] | map(select(.name == "terraform-02"))' - didn't work, to
Given a basic json { "notKnown": { "alpha" : { "hello":"world" } } } and then using getpath with a wildcard as an object
I have an json file as follows below- { "key1": [ "value1" ], "key2": [ "value2" ], "key3": [ "value3" ], "key4": { "name": "value
I have a json file with data as below : { "0cef7017-e6af-4c92-9e7c-4db1d7afc733": { "Show": [ "TEST1", "TEST2" ], "data1": 12345,
I have this input data: [ { "attributes": { "created": "2021-10-18T12:02:39+00:00", "enabled": true, "expires": null, "notBefore":