GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - lilactown/eql-cli: A CLI for executing EQL queries on EDN data

BranchesTags
Open more actions menu

Latest commit

 

History

16 Commits
16 Commits

Folders and files

NameName
Last commit message
Last commit date
src/town/lilac
src/town/lilac
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
TODO.md
TODO.md
 
 
bb.edn
bb.edn
 
 
deps.edn
deps.edn
 
 
eql
eql
 
 
prelude
prelude
 
 
version.txt
version.txt
 
 

Repository files navigation

eql-cli

A command line script for executing EQL queries on EDN data. Powered by pyramid and babashka.

Install

Homebrew

brew install lilactown/brew/eql

Scoop

See https://github.com/littleli/scoop-clojure#tools

Manual

  • Install babashka
  • Download the eql script and place it on your PATH.

Usage

eql --query '[:foo]' '{:foo 123 :bar 456}'

Returns {:foo 123} as the result.

Data is also accepted over STDIN, so you can do the following

echo '{:foo 123 :bar 456}' | eql --query '[:foo]'

Usecases

EQL over arbitrary data can be useful as a "select-keys on steroids" for deep nested data.

curl -s https://pokeapi.co/api/v2/pokemon/ditto | # fetch some data
jet --from json --to edn --keywordize | # convert it from JSON to EDN
eql --query "[:id :name :height :weight \
             {:abilities [{:ability [:name]}]}]" | # select just the keys we want
jet # pretty print

Outputs

{:abilities [{:ability {:name "limber"}} {:ability {:name "imposter"}}],
 :height 3,
 :id 132,
 :name "ditto",
 :weight 40}

About

A CLI for executing EQL queries on EDN data

Topics

babashkaclojureednedn-dataeqlquery-language

Resources

Readme
Activity

Stars

50 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Used by

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.