Iterating through JSON array in Shell script
问题 I have a JSON data as follows in data.json file [ {"original_name":"pdf_convert","changed_name":"pdf_convert_1"}, {"original_name":"video_encode","changed_name":"video_encode_1"}, {"original_name":"video_transcode","changed_name":"video_transcode_1"} ] I want to iterate through the array and extract the value for each element in a loop. I saw jq. I find it difficult to use it to iterate. How can I do that? 回答1: Just use a filter that would return each item in the array. Then loop over the