Format aws-cli output as CSV
One of my recurring annoyances is that the AWS cli utility doesn’t support a CSV output option. This command fixes this (at least for snapshot data). aws ec2 describe-snapshots –owner-ids 12345 –output json |jq -r ‘.Snapshots[] | [.Description, .Encrypted, .OwnerId, .Progress, .SnapshotId, .StartTime, .State, .VolumeId, .VolumeSize, .StorageTier] | @csv’ >snapshots.csv …