Debian Codegraph @

docs/integrations/yq.md

raw
1 If you are familiar with [jq](https://github.com/jqlang/jq) you may be interested to know that
2 there is a similar tool specifically built for yaml files named
3 [yq](https://mikefarah.gitbook.io/yq).
4
5 This tool comes in handy if you are every looking to combine a yaml configuration file
6 with any sort of script or tooling.
7 For instance, if you ever want to pull your changie kind keys out into a list and process.
8
9 Below is a small sample of commands you can run.
10
11 ## Kind keys
12
13 ```sh
14 yq '.kinds[].key' .changie.yaml
15 ```
16
17 Output
18 ```
19 added
20 changed
21 deprecated
22 removed
23 fixed
24 security
25 ```
26
27 ## Kind labels
28
29 ```sh
30 yq '.kinds[].label' .changie.yaml
31 ```
32
33 Output
34 ```
35 ✨ Added
36 🔥 Changed
37 ⚰️ Deprecated
38 🗑️ Removed
39 🪲 Fixed
40 🦺 Security
41 ```
42
43 ## Custom keys
44
45 ```sh
46 yq '.custom[].key' .changie.yaml
47 ```
48
49 Output
50 ```
51 Issue
52 ```