Live data from Hacker News

Show HN: I wrote a program to convert lines of text into trees

github.com

1–10 of 58 posts

Re: Show HN: I wrote a program to convert lines of text into trees

#6
post #2

Author here: Often I have to digest log files and lists of Azure resource names. I prefer to work with hierarchies of things, so I wrote this simple filter. Turns out to quite handy, especially when combined with awk and its friends.

Very cool tool! Any chance that you're going to add it to Homebrew?

Re: Show HN: I wrote a program to convert lines of text into trees

#7
post #2

Author here: Often I have to digest log files and lists of Azure resource names. I prefer to work with hierarchies of things, so I wrote this simple filter. Turns out to quite handy, especially when combined with awk and its friends.

Great, very handy! Just FYI `readlink -f` doesn't work on macOS

May I suggest the name txtree?

Re: Show HN: I wrote a program to convert lines of text into trees

#8
This is really very nice and useful! I read through the examples and thought about something that would be a good addition and then see that “-skip” was just implemented! I can skip (pun intended) using an additional layer of cut or awk because of this.

The detailed examples are great too, showing different use cases and features.

Thank you very much for creating this tool and sharing it.

Re: Show HN: I wrote a program to convert lines of text into trees

#10
Maybe this is not super relevant, but my favorite hack is that any tree-like structure like this can be browsed with ncdu. Here's a gist for breaking down redis traffic by command for example: https://gist.github.com/petethepig/0f33c910fb2edad8969a5775e...
Post reply on HN