Last active
August 8, 2024 22:28
-
-
Save wallentx/36c186cd471741b4ec78cff76c7fc0fd to your computer and use it in GitHub Desktop.
Real footage of me figuring out a `yq` command
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16:00:54 free -h | yq -pp | |
16:01:06 free -h | yq -pp -oy | |
16:01:17 free -h | yq | |
16:01:19 free -h | yq . | |
16:01:22 free -h | yq -pt | |
16:03:38 free -h | yq -pp | sed 's/total/\\ttotal/g' | |
16:03:44 free -h | yq -pp | sed 's/total/\\\ttotal/g' | |
16:03:49 free -h | yq -pp | sed 's/total/\\\\ttotal/g' | |
16:03:56 free -h | yq -pp | sed 's/total/\\ttotal/g' | |
16:03:59 free -h | yq -pp | sed 's/total/\ttotal/g' | |
16:04:04 free -h | yq -pp | sed 's/total/\t\ttotal/g' | |
16:04:25 free -h | sed 's/total/\t\ttotal/g' | yq -pp | |
16:04:52 free -h | yq -pp | |
16:06:02 yq /proc/meminfo | |
16:06:17 yq -pp -oy /proc/meminfo | |
16:12:26 yq -pp -oy '.memory = {.}' /proc/meminfo | |
16:12:33 yq -pp -oy '.memory = {..}' /proc/meminfo | |
16:12:39 yq -pp -oy '.memory = {}' /proc/meminfo | |
16:12:49 yq -pp -oy '.memory = | .' /proc/meminfo | |
16:12:55 yq -pp -oy '.memory = | {.}' /proc/meminfo | |
16:13:07 yq -pp -oy '.memory = [.]' /proc/meminfo | |
16:13:20 yq -pp -oy 'memory = [.]' /proc/meminfo | |
16:13:25 yq -pp -oy '.memory = [].' /proc/meminfo | |
16:13:28 yq -pp -oy '.memory = []' /proc/meminfo | |
16:13:34 yq -pp -oy '.memory = | []' /proc/meminfo | |
16:13:38 yq -pp -oy '.memory = | . []' /proc/meminfo | |
16:13:54 yq -pp -oy /proc/meminfo | |
16:15:29 yq -pp -oy '.memory = []' /proc/meminfo | |
16:15:39 yq '.memory = []' | |
16:15:41 yq '.memory = []' . | |
16:16:00 yq '.memory = []' /proc/meminfo | |
16:16:08 yq -h | |
16:16:30 yq '.memory = []' -n | |
16:16:38 yq -n '.memory = []' | |
16:17:11 yq -pp -oy /proc/meminfo | |
16:19:53 yq -n '.memory = []' | yq -pp -oy /proc/meminfo | |
16:20:34 yq -n '.memory = {$(yq -pp -oy /proc/meminfo)}' | |
16:20:48 yq -n '.memory = {`$(yq -pp -oy /proc/meminfo)`}' | |
16:21:10 yq eval -p '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo | |
16:21:23 yq -p '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo | |
16:21:27 yq -p '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo -oy | |
16:21:34 yq -pp -oy '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo | |
16:21:39 yq -py -oy '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo | |
16:21:42 yq -oy '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo | |
16:21:56 yq -pp -oy '.memory = (. | split("\n") | map({key: capture("^([^:]+):"), value: capture("([0-9]+) kB$")}) | from_entries)' /proc/meminfo | |
16:22:30 yq '.memory = []' /proc/meminfo | |
16:22:48 yq '.memory = [] | .' /proc/meminfo | |
16:22:57 yq '[.memory = [] | .]' /proc/meminfo | |
16:23:06 yq '.memory = ' /proc/meminfo | |
16:23:09 yq '.memory = .' /proc/meminfo | |
16:23:23 yq '[.memory = .]' /proc/meminfo | |
16:23:41 yq '. | [.memory = .]' /proc/meminfo | |
16:23:51 yq '. | .memory = .' /proc/meminfo | |
16:23:58 yq '. | .memory = {.}' /proc/meminfo | |
16:25:42 yq '. | .memory = .' /proc/meminfo | |
16:25:48 yq '(.) | .memory = .' /proc/meminfo | |
16:26:18 yq '.memory = [] | .' /proc/meminfo | |
16:26:26 yq '.memory = [] | . // []' /proc/meminfo | |
16:26:33 yq '.memory = [] | // []' /proc/meminfo | |
16:26:40 yq '. | // []' /proc/meminfo | |
16:26:45 yq '. | . // []' /proc/meminfo | |
16:26:50 yq '. | . // [.]' /proc/meminfo | |
16:27:00 yq '. | . // [[]]' /proc/meminfo | |
16:27:08 yq '.memory | . // []' /proc/meminfo | |
16:27:17 yq '.memory = . | . // []' /proc/meminfo | |
16:27:23 yq '.memory = | . // []' /proc/meminfo | |
16:27:31 yq '.memory = [] | .. // []' /proc/meminfo | |
16:27:41 yq '.memory = [ | .. // []]' /proc/meminfo | |
16:27:53 yq '.memory = [ | . // []]' /proc/meminfo | |
16:28:04 yq '.memory = {} | . // []]' /proc/meminfo | |
16:28:07 yq '.memory = {} | . // []' /proc/meminfo | |
16:28:13 yq '.memory = {} | .. // []' /proc/meminfo | |
16:28:27 yq '.memory = { | . // []}' /proc/meminfo | |
16:28:39 yq '.memory = {} | . // {}' /proc/meminfo | |
16:28:51 yq '.memory = {} | . {}' /proc/meminfo | |
16:28:55 yq '.memory = {} | . ' /proc/meminfo | |
16:29:05 yq '.memory = . // {}' /proc/meminfo | |
16:29:13 yq '.memory = .. // {}' /proc/meminfo | |
16:29:20 yq '. | .memory = . // {}' /proc/meminfo | |
16:29:24 yq '. | .memory = .. // {}' /proc/meminfo | |
16:29:32 yq '[]. | .memory = .. // {}' /proc/meminfo | |
16:29:37 yq '[.] | .memory = .. // {}' /proc/meminfo | |
16:29:41 yq '[.] | .memory = . // {}' /proc/meminfo | |
16:29:46 yq '[.] | ..memory = . // {}' /proc/meminfo | |
16:29:53 yq '[] | .memory = . // {}' /proc/meminfo | |
16:29:59 yq '. | .memory = . // {}' /proc/meminfo | |
16:30:20 yq '. | .memory = .. // {}' /proc/meminfo | |
16:30:24 yq '... | .memory = . // {}' /proc/meminfo | |
16:30:31 yq '.. | .memory = . // {}' /proc/meminfo | |
16:30:40 yq '. | .memory = . // {}' /proc/meminfo | |
16:30:46 yq '. | .memory = . | // {}' /proc/meminfo | |
16:30:52 yq '. | .memory = . // | {}' /proc/meminfo | |
16:30:56 yq '. | .memory = . // | . {}' /proc/meminfo | |
16:31:01 yq '. | .memory = . // | .memory {}' /proc/meminfo | |
16:31:05 yq '. | .memory = . // | .memory' /proc/meminfo | |
16:31:11 yq '. | .memory[] = . // | .memory' /proc/meminfo | |
16:31:15 yq '. | .memory[] = . // .memory' /proc/meminfo | |
16:31:24 yq '. | .memory[] = . // [.memory]' /proc/meminfo | |
16:31:33 yq '. | .memory[] = . // .memory[]' /proc/meminfo | |
16:31:38 yq '. | .memory = . // .memory[]' /proc/meminfo | |
16:31:46 yq '. | .memory = [] // .memory[]' /proc/meminfo | |
16:31:52 yq '.memory = [] // .memory[]' /proc/meminfo | |
16:31:57 yq '.memory = [] | . // .memory[]' /proc/meminfo | |
16:32:11 yq '.memory = [] | . // .memory[.]' /proc/meminfo | |
16:32:23 yq '.memory = [] | .memory[.]' /proc/meminfo | |
16:32:28 yq '.memory = [] | .memory[]' /proc/meminfo | |
16:32:34 yq '.memory = [] | .. | .memory[]' /proc/meminfo | |
16:32:38 yq '.memory = [] | .. | .' /proc/meminfo | |
16:32:48 yq '.memory = [] | .. ' /proc/meminfo | |
16:32:56 yq '.memory = [] | . ' /proc/meminfo | |
16:33:06 yq '.memory = [] | .. ' /proc/meminfo | |
16:33:10 yq '.memory = [] | ... ' /proc/meminfo | |
16:33:23 yq '.. | .memory = []' /proc/meminfo | |
16:33:40 yq '.. | .memory' /proc/meminfo | |
16:33:47 yq '.. | .memory[]' /proc/meminfo | |
16:33:54 yq '.. | . // .memory[]' /proc/meminfo | |
16:34:05 yq '.. | .. // .memory[]' /proc/meminfo | |
16:34:13 yq '.. | .. // .memory = []' /proc/meminfo | |
16:34:18 yq '.. | . // .memory = []' /proc/meminfo | |
16:34:21 yq '. | . // .memory = []' /proc/meminfo | |
16:34:25 yq '. // .memory = []' /proc/meminfo | |
16:34:31 yq '. // .memory = [] | .' /proc/meminfo | |
16:34:50 yq '.memory = { .. }' /proc/meminfo | |
16:34:55 yq '.memory = { . }' /proc/meminfo | |
16:35:04 yq '.memory = { .. }' /proc/meminfo | |
16:35:08 yq '.memory = { ... }' /proc/meminfo | |
16:35:16 yq '.memory = {( ... )}' /proc/meminfo | |
16:35:20 yq '.memory = {( ...)}' /proc/meminfo | |
16:35:28 yq '.memory = {[ ]}' /proc/meminfo | |
16:35:33 yq '.memory = {[.]}' /proc/meminfo | |
16:35:37 yq '.memory = {[..]}' /proc/meminfo | |
16:36:36 yq -pp -oy /proc/meminfo | |
16:36:41 yq -pp -oy /proc/meminfo | |
16:36:44 yq -pp -oy /proc/meminfo -P | |
16:49:29 yq -pp -oy /proc/meminfo -s | |
16:49:46 yq -pp -oy /proc/meminfo -r | |
16:49:49 yq -pp -oy /proc/meminfo -c | |
16:49:55 yq -pp -oy /proc/meminfo -h | grep single | |
16:49:57 man yq | |
16:50:42 man yq | |
16:51:00 yq -pp -oj /proc/meminfo | jq -c | |
16:51:02 yq -pp -oj /proc/meminfo | jq -c | yq | |
16:51:09 yq -pp -oj /proc/meminfo | jq -c | yq -pj -oy | |
16:51:13 yq -pp -oj /proc/meminfo | jq -c | yq | |
16:51:29 yq -pp -oj /proc/meminfo | |
16:51:31 yq -pp -oj /proc/meminfo -c | |
16:51:34 yq -pp -oj /proc/meminfo -s | |
16:52:48 yq -pp -oj /proc/meminfo | jq -c | |
16:53:32 yq '.memory = {"MemTotal":"528210616 kB","MemFree":"505554580 kB","MemAvailable":"521397796 kB","Buffers":"4744 kB","Cached":"18109600 kB","SwapCached":"0 kB","Active":"13575320 kB","Inactive":"4766300 kB","Active(anon)":"602412 kB","Inactive(anon)":"0 kB","Active(file)":"12972908 kB","Inactive(file)":"4766300 kB","Unevictable":"16320 kB","Mlocked":"16320 kB","SwapTotal":"0 kB","SwapFree":"0 kB","Zswap":"0 kB","Zswapped":"0 kB","Dirty":"0 kB","Writeback":"0 kB","AnonPages":"243772 kB","Mapped":"191520 kB","Shmem":"368712 kB","KReclaimable":"964140 kB","Slab":"1387872 | |
16:53:49 yq -pp -oj /proc/meminfo | jq -rc | |
16:53:58 yq -pp -oj /proc/meminfo | jq -rc '.' | |
16:54:02 yq -pp -oj /proc/meminfo | jq -rc '..' | |
16:54:09 yq -pp -oj /proc/meminfo | jq -rc '.[]' | |
16:54:15 yq -pp -oj /proc/meminfo | jq -rc '[.]' | |
16:54:42 yq -pp -oj /proc/meminfo | jq -r '.' | |
16:54:44 yq -pp -oj /proc/meminfo | jq -r '' | |
16:54:46 yq -pp -oj /proc/meminfo | jq -r | |
16:55:05 yq -pp -oj /proc/meminfo | jq -R | |
16:55:07 yq -pp -oj /proc/meminfo | jq -s | |
16:55:10 yq -pp -oj /proc/meminfo | jq - | |
16:55:12 yq -pp -oj /proc/meminfo | jq | |
16:55:16 yq -pp -oj /proc/meminfo | jq -s | |
16:55:17 yq -pp -oj /proc/meminfo | jq -sr | |
16:55:46 yq -pp -oj /proc/meminfo | jq -sr '.|.[] | |
16:56:07 yq -pp -oj /proc/meminfo | jq -sr '[.|.[]]' | |
16:56:17 yq -pp -oj /proc/meminfo | jq -sr '..|.[]' | |
16:56:21 yq -pp -oj /proc/meminfo | jq -sr '..|.' | |
16:56:23 yq -pp -oj /proc/meminfo | jq -sr '..|..' | |
16:56:25 yq -pp -oj /proc/meminfo | jq -sr '...|..' | |
16:56:27 yq -pp -oj /proc/meminfo | jq -sr '...|' | |
16:56:29 yq -pp -oj /proc/meminfo | jq -sr '...|..' | |
16:56:31 yq -pp -oj /proc/meminfo | jq -sr '|..' | |
16:56:34 yq -pp -oj /proc/meminfo | jq -sr '..' | |
16:56:39 yq -pp -oj /proc/meminfo | jq -sr '[.]' | |
16:56:42 yq -pp -oj /proc/meminfo | jq -sr '.' | |
16:56:46 yq -pp -oj /proc/meminfo | jq -r '.' | |
16:56:53 yq -pp -oj /proc/meminfo | jq -r '. | .' | |
16:57:45 yq -pp -oj /proc/meminfo | jq -r '.' | jq -r | |
16:57:58 yq -pp -oj /proc/meminfo | jq -r '.' | jq --raw-output | |
16:59:45 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k]),"' | |
16:59:51 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k])"' | |
17:00:37 yq -pp -oj /proc/meminfo | jq -rc '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k]),"' | |
17:00:45 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k]),"' | |
17:00:59 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k]),"' | jq | |
17:01:01 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k]),"' | jq . | |
17:01:04 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | "\($k): \($in[$k])"' | |
17:01:14 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | \($k): \($in[$k])' | |
17:01:23 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k' | |
17:01:30 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[]' | |
17:01:50 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k:' | |
17:02:00 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | \($k):' | |
17:02:19 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | \($k): \($k)' | |
17:02:29 yq -pp -oj /proc/meminfo | jq -c -r '. as $in | keys_unsorted[] as $k | ($k): ($k)' | |
17:02:39 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | ($k): ($k)' | |
17:02:44 yq -pp -oj /proc/meminfo | jq '. as $in | keys_unsorted[] as $k | ($k): ($k)' | |
17:02:49 yq -pp -oj /proc/meminfo | jq '. as $in | keys_unsorted[] as $k | ($k)' | |
17:02:53 yq -pp -oj /proc/meminfo | jq '. as $in | keys_unsorted[] as $k | $k' | |
17:03:01 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | $k' | |
17:03:03 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | .$k' | |
17:03:06 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | \.$k' | |
17:03:12 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | $k:' | |
17:03:19 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | $k+:' | |
17:03:27 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | $k+":"' | |
17:03:39 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | $k+": ."' | |
17:03:46 yq -pp -oj /proc/meminfo | jq -r '. as $in | keys_unsorted[] as $k | $k+": ."+$k' | |
17:04:13 yq -pp -oj /proc/meminfo '. as $in | keys_unsorted[] as $k | $k+": ."+$k' | |
17:04:24 yq -pp -oj /proc/meminfo | yq '. as $in | keys_unsorted[] as $k | $k+": ."+$k' | |
17:05:02 yq -pp -oj /proc/meminfo | yq '. as $in | keys_unsorted[] as $k | $k+": ."+$k' | |
17:05:15 yq -pp -oy '. as $in | to_entries | map("\(.key): \(.value)") | join(",")' /proc/meminfo | |
17:05:19 yq -pp -oj '. as $in | to_entries | map("\(.key): \(.value)") | join(",")' /proc/meminfo | |
17:05:39 yq -pp -oy '. as $in | to_entries | map("\(.key): \(.value)") | join("\n")' /proc/meminfo | |
17:05:53 yq -pp -oy '. as $in | to_entries | map("\(.key): \(.key)") | join("\n")' /proc/meminfo | |
17:05:59 yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo | |
17:07:11 yq '.memory = {`yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo`}' | |
17:07:26 yq '.memory = {'$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo)'}' | |
17:07:36 yq '.memory = {+'$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo)'+}' | |
17:08:01 bash -c yq '.memory = {+'$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo)'+}' | |
17:08:08 yq '.memory = {+'$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo)'+}' | |
17:08:19 yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join("\n")' /proc/meminfo | |
17:08:30 yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join(",")' /proc/meminfo | |
17:08:37 yq '.memory = {+'$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join(",")' /proc/meminfo)'+}' | |
17:08:52 yq '.memory = {$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join(",")' /proc/meminfo)}' | |
17:08:58 yq '.memory = {+'$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join(",")' /proc/meminfo)'+}' | |
17:09:08 FUDGE=$(yq -pp -oy '. as $in | to_entries | map("\(.key): .\(.key)") | join(",")' /proc/meminfo) | |
17:09:26 yq '.memory = {+'$FUDGE'+}' | |
17:10:13 yq eval -p '.memory = { | |
17:10:37 yq -pp -oy6 '.memory = { | |
17:10:42 yq -pp -oy '.memory = { | |
17:10:56 yq -pp -oj '.memory = { | |
17:11:01 yq -pp -op '.memory = { | |
17:11:29 yq -P '.memory = { | |
17:12:59 yq '.memory = []' | |
17:13:03 yq -n '.memory = []' | |
17:13:22 yq -n '.memory[] = []' | |
17:13:25 yq -n '.memory[] = .' | |
17:17:33 yq -n '{"memory": .}' -pp -oy /proc/meminfo | |
17:17:37 yq '{"memory": .}' -pp -oy /proc/meminfo | |
17:17:53 yq -pp -oy '{"memory": .}' /proc/meminfo |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
yq -pp -oy '{"Memory": .}' /proc/meminfo