Skip to content

Instantly share code, notes, and snippets.

@keyle
Last active August 29, 2015 13:58
Show Gist options
  • Select an option

  • Save keyle/10227604 to your computer and use it in GitHub Desktop.

Select an option

Save keyle/10227604 to your computer and use it in GitHub Desktop.
webql2
keywords
from <url|rss|google|ddg>
select <jqueryStyleSelector>
where <attr.name|value> <contains|!contains|match> <string|regexp>
limit <num>
skip <num>
reverse
shuffle
first
last
nth <num>
to <text|csv|json|table>
example
$ webql from http://news.ycombinator.com select a.html, a.href where a.href !contains combinator.com to csv
rough translation
webql
.from('http://news.ycombinator.com')
.select(['a.html', 'a.href']
.where('!contains', 'a.href', 'combinator.com')
.to('csv')
.init();
repl
$ webql
from http://news.ycombinator.com
select a.html|a.href
where a.href !contains combinator.com
to csv
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment