HNHacker News
TopNewBestAskShowJobs

code-faster

358 karma · joined May 7, 2020

I'm all about developer productivity. If you want to be more productive, subscribe to my newsletter https://codefaster.substack.com

@canardivore on twitter

submissionscomments
code-faster··on Make Ubuntu packages 90% faster by rebuilding them
Could you release a fork of jq whose make does all this fanciness? I use jq A LOT so would love a turnkey solution to make it faster.
code-faster··on New junior developers can’t code
The reason why these articles appear every 5 years is because many engineers pride themselves on how they solve problems. And then when they see people solving those problems without putting in the hard work that they had to put in, it really bothers them.

This is a timeless post. We'll see it today. We'll see it in five years. We'll see it in 10 years.

code-faster··on Half-Life 2 and Dishonored art lead Viktor Antonov has died
He was great, he deserves, in death, no dishonor
code-faster··on I spent 18 years in the Linux console
I love pieces like this. They're great programmer sociology if such a field existed.
code-faster··on Why is it so hard to buy things that work well? (2022)
Will AI change this? If AI can assess who is good for us, then we can get somewhere
code-faster··on JSON parsers that can accept comments
All you're doing is creating a new spec that's not JSON. JSON has no comments. Your spec does. Your parsers handle both specs.

https://xkcd.com/927/ applies

code-faster··on Tyler-Style Font Maker
I had to double take back to HN that this wasn't some super custom website pulling my name out of cookies.
code-faster··on Show HN: Comma Separated Values (CSV) to Unicode Separated Values (USV)
CSV is great because excel can import it, but it can't import USV, so at that point, why use USV when you can use JSON?

https://github.com/tyleradams/json-toolkit/

code-faster··on A man has been swatted 47 times for making a joke about Norm Macdonald
Let's do both. There's two crimes:

1 - Giving away info without consent

2 - The crime of abusing police resources.

code-faster··on A man has been swatted 47 times for making a joke about Norm Macdonald
Seems like the corporations are criminally negligent for leaking customer info. What if the best way to stop swatting was to go after them?
code-faster··on PostgreSQL is enough
A response: https://codefaster.substack.com/p/postgres-is-enough-but-is-...
code-faster··on Analyzing multi-gigabyte JSON files locally
> Also note that this approach generalizes to other text-based formats. If you have 10 gigabyte of CSV, you can use Miller for processing. For binary formats, you could use fq if you can find a workable record separator.

You can also generalize it without learning a new minilanguage by using https://github.com/tyleradams/json-toolkit which converts csv/binary/whatever to/from json

code-faster··on Fq: Jq for Binary Formats
https://github.com/tyleradams/json-toolkit

Convert json <-> xml, csv, yaml, logfmt

So to support all formats, you write a binary <-> json converter.

code-faster··on M4 as a templating language (2020)
Having used m4 in practice, it's easier to get the job done with a custom python script.
code-faster··on Show HN: Angle Grinder – A terminal app to slice, dice, and aggregate your logs
I really like this tool, but I'm not sure what it gets me more than jq (and https://github.com/tyleradams/json-toolkit to convert non-json to json).

What can angle grinder do better than jq?

code-faster··on Show HN: Transform a CSV into a JSON and vice versa
I have a couple of open source CLI tools to do this: - https://github.com/tyleradams/json-toolkit/blob/master/csv-t... - https://github.com/tyleradams/json-toolkit/blob/master/json-...
code-faster··on Congress should invest in open-source software
Can't we setup a school Today that does R&D in open source tech and apply for research grants?
code-faster··on Look ma, no mouse: Vimium
Oh that's cool, thanks for the tip
code-faster··on Emacs is special regarding UIs
unix is also User Interface Independent, but unlike emacs, it's actually used on a wide variety of interfaces: Mainframes, microcontrollers, web servers, phones (touch screen) and PCs.
code-faster··on Fast Typing: Keyboard Layouts
Hi, I'm the author, I would love to know more about proper typing training, I've never heard of such a thing beyond touch typing. Do you have any suggested online resources or books for where I could start?
code-faster··on [dead]
Thank you. As someone starting a newsletter, it can be frustrating to get a few views for high quality content. Meanwhile its my basic tutorial that got to the front page of HN.

Obviously thats a different league, but I bet the temptation to get a "high score" feels the same. This post is a good reminder not to worry so much about the score, so thanks again

code-faster··on Ask HN: What weird or hard problems are you trying to solve?
Hard: Tech

Harder: People

Impossibly hard: Help people get faster at building tech

And yet it's all I want to do.

https://codefaster.substack.com

code-faster··on Mastering Jq: Part 1
Is there anything in my tutorial that I can help clarify for you?
code-faster··on Mastering Jq: Part 1
Nice! I've found xml transforms is one of the best applications of jq (yes, jq, not xq).

In a future post, I'll cover how to use jq not just for json and xml but any data format.

code-faster··on Mastering Jq: Part 1
You can use any language with json support, which is most languages.

In python, you can have a jq like experience with

  def f(data):
    # put code here

  data = json.load(sys.stdin)
  output = f(data)
  print(json.dumps(output))
code-faster··on Mastering Jq: Part 1
It is a weird way to write it, I never use this notation for myself.

When teaching though, I'd rather make the it more visually explicit that jq commands are a sequence of filters. With the former notation, a | explicitly tells the reader that it's the end of one filter and the start of a new one, the latter is more implicit.

code-faster··on Mastering Jq: Part 1
I would also be fascinated to hear how you're using it.
code-faster··on Mastering Jq: Part 1
Thanks for flagging that, they've been fixed and retested, thank you jbotz!
code-faster··on Ask HN: Which tools have made you a much better programmer?
my json toolkit has been a huge boon for me, it complements jq very well: https://github.com/tyleradams/json-toolkit

There's tools for converting between json and other data formats like xml as well as misc tools like json-diff which diffs json files and formats the output as json.

code-faster··on XML Is Not Injective
Ah, they're meant to be xml fragments, not full xml documents.

In my limited experience I haven't seen people use the <array> container and the xml parser still works, although it is a good idea.

Page 1 of 2Next →