I found out shortly after implementing the ".." shorthand that this conflicts with a shorthand in jq itself (.. performs recursive descent).
I'm not sure how useful recursive descent is. I find it fairly useless (though I have used "//" in xpath before). Further, the syntax causes weird problems in jq itself (e.g. "..a" doesn't work).
What I find the most troubling is that jq's interpretation of ".." is basically completely opposite of how jqsh (and unix itself) interpret those symbols. That is, in unix it means "go up one level" in jq it means "go down as many levels as possible".
I found out shortly after implementing the ".." shorthand that this conflicts with a shorthand in jq itself (.. performs recursive descent).
I'm not sure how useful recursive descent is. I find it fairly useless (though I have used "//" in xpath before). Further, the syntax causes weird problems in jq itself (e.g. "..a" doesn't work).
What I find the most troubling is that jq's interpretation of ".." is basically completely opposite of how jqsh (and unix itself) interpret those symbols. That is, in unix it means "go up one level" in jq it means "go down as many levels as possible".