Ranter
Join devRant
Do all the things like
				++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
				Sign Up
			Pipeless API
 
				From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
				Learn More
			Comments
		
- 
				
				Spectacular!
 It's an amazing util. And it's far, far more than just grep :) it's a full blown json scripting language
- 
				
				@magicMirror yes but what if you have to use bash scripts?
 
 I'd use js/node if I had the chance to too.
- 
				
				@melezorus34
 Yep. You can't count of the right version of python being present in every env anymore
- 
				
				JSON isn't my format of choice when it comes to shell scripting, but I definitely had some used for it.
 And it seems to work really well.
- 
				
				@Oktokolo yes, and more. As xpath, it supports selection/filter mechanism. But you can also reshape, join, create jsons using it, format as tables or other output fmt
- 
				
				@netikras
 so it is a turing-complete language - like Perl - but for parsing JSON instead of semi-regular (*g*) strings?
- 
				
				@Oktokolo think of it like 'awk for JSON'. IMO it's closer to the AWK language than Perl. It feels like AWK with a taste of SQL (in a sense of field-mapping).
 
 Just look it up :) There's plenty of code examples.
- 
				
				@melezorus34 What platform does not have python, but has bash?
 
 Python is easier to write scripts for, with no need for obscure cli crap....
- 
				
				abrd17115yAmazing util! I use it a lot in CI to insert specific parts from a JSON artifact :)
 Just love it!
Related Rants
- 
						
							 nickj58today at programming class... professor: today we will be teaching you about vim and using the terminal and s... nickj58today at programming class... professor: today we will be teaching you about vim and using the terminal and s...
- 
						
							alexjamesbrown16Status code: 200 Content-Type: application/json Body: {"error": true, "responseCode":400 }
- 
						
							 fyzrn40Me: *just playing around with Git on my terminal* Friend: "Man, you're such a geek, typing your git command o... fyzrn40Me: *just playing around with Git on my terminal* Friend: "Man, you're such a geek, typing your git command o...










What's you guys' thought about jq?
It's grep, but for json.
question
json
jq
cli