Hacker Newsnew | past | comments | ask | show | jobs | submit | BaltoRouberol's commentslogin

https://github.com/kellyjonbrazil/jc can come pretty handy there


oh my god, why?! just why!?

What the world needs is the inverse program of "jc", where an unparseable json string is expanded into a flat list of lines all of the form "field.subfield=value"


If you search for "gron", you will find a family of such tools, e.g., https://github.com/tailhook/rust-gron.


Thanks, that's just what I needed!


ok well I can understand not wanting json when all you need is something simpler, but I'm not sure if I understand unparseable - I mean if it is JSON then it is parseable.


You can only parse json easily by using json libraries. Plain text, or "field=value" pairs, you can easily cut(1) or grep(1), or sed(1) to your pleasure. This is what I mean by parseable. Parseable trivially by tools that do not understand the format. I can also sed and awk json files, and I do, but it is extremely painful; and more often than not these files are nothing more than simple lists of variables with values, for which the use of json is a ridiculous overkill.


Ok, but I believe that your use of the word parseable diverges quite a bit from common usage.


thanks!


Author here. Quick sidenote: this is chapter 2 of a book aiming at teaching the terminal and related tooling (make, jq, regular expressions, etc) to beginners and people trying to become developers.

I've been on the job for 10 years and I still use these tools daily. For example, I sent a PR yesterday that was adding a configuration entry on 150+ config files by using find, grep and sed.

I'm not pretending these are the only tools that exist, but darn are they handy sometimes, and good to have in your toolbelt.


Please don’t take it wrong, I like what I read so far! It was just my random observation


bwhaha that's insane


Exactly what I thought too.


Yes, this plugin is pretty awesome :) Also note that this is not a work of mine, so any remark, bug report, etc should be filed on Github.


Here are some other great free Python ressources: http://www.awaretek.com/tutorials.html http://pythonbooks.revolunet.com/


I think people should be able to see what it's about before having to log in.


Aye, I haven't quite figured out how to do that yet. I want to offer a way of exploring entries but that relies on there being entries in the first place :)


I guess it should be "pip install jarvis" and not "pip install pip". Very nice tool!


Thanks ! Typo should be fixed now !


Oh, that's just a typo. My bad. Edit: there, corrected.


Yeah, I actually learnt scraping from Asheesh :) He's awesome.


I have been playing with scraping for quite some time now and have my own scripts and stuff, but I found that video informing and there were a few useful snippets I had missed.

Keep meaning to check out more of the Pycon vids


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: