问题: I'm trying to parse JSON returned from a curl request, like so: 我正在尝试解析从curl请求返回的JSON,如下所示: curl 'http://twitter.com/users/username.json' | sed -e 's/[{}]/''/g' | awk -v k="text" '{n=split($0,a,","); for (i=1; i<=n; i++) print a[i]}' The above splits the JSON into fields, for example: 上面将JSON分为多个字段,例如: % ... "geo_enabled":false "friends_count":245 "profile_text_color":"000000" "status":"in_reply_to_screen_name":null "source":"web" "truncated":false "text":"My status" "favorited":false % ... How do I print a specific field (denoted by the -vk=text )? 如何打印特定字段(由 -vk=text )? 解决方案: 参考一: https: