This commit adds the --format tag to all of the autocompletion functions. The default format changed from json to a "human readable" format as of version 0.10. This change should be backward compatible. Alternatively, these commands could be simplified by using the new default human readable format.
| ... | ... | @@ -138,27 +138,27 @@ _knife_options3() { | 
| 138 | 138 |  | 
| 139 | 139 | # The chef_x_remote functions use knife to get a list of objects of type x on the server | 
| 140 | 140 |  _chef_roles_remote() { | 
| 141 | - (knife role list | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 141 | + (knife role list --format json | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 142 | 142 | } | 
| 143 | 143 |  | 
| 144 | 144 |  _chef_clients_remote() { | 
| 145 | - (knife client list | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 145 | + (knife client list --format json | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 146 | 146 | } | 
| 147 | 147 |  | 
| 148 | 148 |  _chef_nodes_remote() { | 
| 149 | - (knife node list | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 149 | + (knife node list --format json | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 150 | 150 | } | 
| 151 | 151 |  | 
| 152 | 152 |  _chef_cookbooks_remote() { | 
| 153 | - (knife cookbook list | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 153 | + (knife cookbook list --format json | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 154 | 154 | } | 
| 155 | 155 |  | 
| 156 | 156 |  _chef_sitecookbooks_remote() { | 
| 157 | - (knife cookbook site list | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 157 | + (knife cookbook site list --format json | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 158 | 158 | } | 
| 159 | 159 |  | 
| 160 | 160 |  _chef_data_bags_remote() { | 
| 161 | - (knife data bag list | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 161 | + (knife data bag list --format json | grep \" | awk '{print $1}' | awk -F"," '{print $1}' | awk -F"\"" '{print $2}') | |
| 162 | 162 | } | 
| 163 | 163 |  | 
| 164 | 164 | # The chef_x_local functions use the knife config to find the paths of relevant objects x to be uploaded to the server |