Coder Social home page Coder Social logo

eq's Introduction

eq

Like jq, but for EDN (and a lot less powerful).

Usage

$ eq [selector [<path>]]

If no path is given, eq reads from stdin. The default selector is . (just like jq).

Examples

# pretty-print each line
cat *.edn | eq .

# pretty-print the :foo-bar value of each line
cat *.edn | eq .foo-bar

# read from a file
eq .name people.edn

Supported selectors

  • .: the object itself. This is identical to giving no selector at all.
  • :foo: Apply :foo to the current object.
  • .foo: Equivalent of :foo but .foo.bar is interpreted as :foo then :bar instead of the :foo.bar keyword.

Install

You need to have Node installed on your machine.

  1. Retrieve this project locally and run ./scripts/build-advanced. You can also download eq.js from the releases page
  2. chmod u+x target/eq.js
  3. Move target/eq.js somewhere in your PATH

With Homebrew on macOS

brew install bfontaine/utils/eq

License

Copyright © 2016-2017 Oscaro

eq's People

Contributors

bfontaine avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

Forkers

morganastra

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.