我有一个示例命令aws describe-something command
,它返回以下输出。
{
"Image": [
{
"Name": "tyy1",
"VpcConfig": {
"SubnetIds": [
"subnet-800jhoic9"
],
"SecurityGroupIds": [
"sg-jj-popttf5"
]
},
"EnableDefaultInternetAccess": false,
"ImageBuilderErrors": [],
"Platform": "WINDOWS",
"State": "SNAPSHOTTING",
"InstanceType": "stream.standard.medium"
}
]
}
我尝试使用此命令aws describe-something | grep -i State | sed -n -e 's/^.*\"State\": //p'
来返回SNAPSHOTTING但是我得到了" SNAPSHOTTING"。如何删除逗号和双引号?