mirror of
https://github.com/mikefarah/yq.git
synced 2026-09-01 14:14:52 +08:00
Minor fixes
This commit is contained in:
@@ -48,3 +48,19 @@ a: cat
|
||||
b: dog
|
||||
```
|
||||
|
||||
### Delete matching entries
|
||||
Given a sample.yml file of:
|
||||
```yaml
|
||||
a: cat
|
||||
b: dog
|
||||
c: bat
|
||||
```
|
||||
then
|
||||
```bash
|
||||
yq eval 'del( .[] | select(. == "*at") )' sample.yml
|
||||
```
|
||||
will output
|
||||
```yaml
|
||||
b: dog
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user