• ArseAssassin@sopuli.xyz
    link
    fedilink
    arrow-up
    5
    ·
    14 hours ago

    I don’t know if we should call someone a master of jq if they do

    echo ‘{“k1”: [{“k2”: [9]}]}’ | jq ‘.k1 | .[0] | .k2 | .[0]’

    Instead of just

    echo ‘{“k1”: [{“k2”: [9]}]}’ | jq ‘.k1[0].k2[0]’