Live data from Hacker News

Jaq – A jq clone focused on correctness, speed, and simplicity

github.com

161–170 of 254 posts

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#161

Earlier quoted context omitted.

I'm American and pronounce Jacques and Jack the way they described. If someone said [ʒak], I would transcribe it as Jacques, and if someone said [dʒæk], I would transcribe it as Jack. It may be a French name, but it's not very foreign. (If I heard [dʒak], I would assume the speaker is British and transcribe it as Jack). I was confused reading people say that Jacques is pronounced the same as Jack, so it does seem lik…

I’d say the amount of time before that sneak edit from Jacques to Jack lends credibility my claim of the two’s “essential interchangability”.

You're implying I subconsciously view them the same and pronounce them the same. But I don't. Maybe your dialect of English is different than mine, but I am not you. And it was there for a while because I use Hacker News on my phone and don't check it all the time.

My original sentence repeated the same word twice as a typo. It was this:

> I was confused reading people say that Jacques is pronounced the same as Jacques.

I realized my mistake and edited it to this:

> I was confused reading people say that Jacques is pronounced the same as Jack.

If we'd been discussing the words "chick" and "chic," I might have accidentally written:

> I was originally confused reading people say that chick is pronounced them the same as chick.

Then I'd realize my error and edit it to:

> I was originally confused reading people say that chick is pronounced them the same as chic.

That doesn't mean I actually pronounce "chick" the same way as "chic" and it doesn't make the words interchangeable in the dialect I speak. "Chic" is pronounced like "Sheikh," referring to the Arab leader, or like "Sheik" from the Legend of Zelda. I'll be confused if you say "a baby Sheikh" instead of "a baby chick," and if you say "chick fashion" instead of "chic fashion" I'll be thrown off but realize you meant "chic."

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#163

It's so awesome when projects shout out other projects that they're similar to or inspired by or not replacements for. I learned about https://github.com/yamafaktory/jql from the readme of this project and it's what I've been looking for for a long time, thank you! That's not to take away from JAQ by any means I just find the JQ style syntax uber hard to grokk so jql makes more sense for me.

Very nice in this regard is gron, too. It simply flattens any json into lines of key value format, making it compatible with grep and other simple stream operations. https://github.com/tomnomnom/gron

This is brilliant, thank you for sharing!

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#165
post #7

This language must be the spiritual successor of Perl

I inherited some piece of code that made use of an extremely long and complicated jq script. I simply gave up understanding the whole thing, and restored the balance in the universe by rewriting it in Perl.

[deleted]

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#166

It's so awesome when projects shout out other projects that they're similar to or inspired by or not replacements for. I learned about https://github.com/yamafaktory/jql from the readme of this project and it's what I've been looking for for a long time, thank you! That's not to take away from JAQ by any means I just find the JQ style syntax uber hard to grokk so jql makes more sense for me.

jql homoiconicity looks rather ... Lispy. Like you could use it on itself, write "Macros", etc.

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#167
post #99

Earlier quoted context omitted.

Nice find. I think I'll try it out. Although I was hoping for a real SQL type experience. I don't understand why no one just copies SQL so I can write a query like "SELECT * FROM $json WHERE x>1". Everyone seems to want to invent their own new esoteric symbolic query language as if everything they do is a game of code golf. I really wish everyone would move away from this old Unix mentality of extremely concise, yet…

Be the change you want to see. I personally don't understand why people aren't willing to learn instead. It's not hard to sit down and pick up a new skill and it's good to step out of one's comfort zone. I personally hate Powershell syntax, brevity is the soul of wit and PS could learn a thing or two from bash and "the linux way". We seem obsessed with molding the machine to our individual preferences. Perhaps we sho…

“Brevity is the soul of wit”

Maybe we have different goals but I don’t get paid to write witty code and I don’t think anyone on my team would appreciate it if I did.

I don’t think the redeeming qualities of brevity in prose transfer to something like terse syntax.

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#168
post #156

How have you been using jq? It is more adhoc for exploring JSON files during development/data analysis or in programs that run in production?

Yeah, I've always liked the idea of jq but personally I find it easier to open a REPL in the language I'm most familiar with (which happens to be JS, which does make a difference) and just paste in the JSON and work with it there

It may be more verbose, but I never have to google anything, which makes a bigger difference in my experience

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#169
post #156

How have you been using jq? It is more adhoc for exploring JSON files during development/data analysis or in programs that run in production?

Yeah, I've always liked the idea of jq but personally I find it easier to open a REPL in the language I'm most familiar with (which happens to be JS, which does make a difference) and just paste in the JSON and work with it there It may be more verbose, but I never have to google anything, which makes a bigger difference in my experience

https://github.com/wader/fq has a REPL and can read JSON. Tip is to use "paste | from_json | repl" in a REPl to paste JSON into a sub-REPL, you can also use `` with fq which is a raw string literal

Re: Jaq – A jq clone focused on correctness, speed, and simplicity

#170
post #160
post #158

Earlier quoted context omitted.

Quite a lot! i use it to explode both JSON and tex (parse using jq functions). I also use it for exploring ane debug binary formats ( https://github.com/wader/fq ). Now a days i also use it for some adhoc programming and a calculator.

Oh sounds a very neat way to explore binary!

If you spend lots of time with certain binary formats then i can recommend adding a decoder, happy to help with it also!
Post reply on HN