Comments (4)
🥳 Think my advice would be to first focus on really nice and fancy completion, that is what i use all the time with fq. sub-repl i use a tiny bit, slurp/spew not at all. "realtime" syntax checking and highlighting would be really nice but i haven't look into it, for fq it would probably also involve quite a lot of work on the readline implementation that i use.
btw if you write lots of jq i can recommend https://github.com/wader/jq-lsp
from qq.
Hey, i can list some fancy things https://github.com/wader/fq supports that might be interesting idea:
- Auto completion of index, function, bindings and keywords. It's also done via eval so you can "complete" a query, ex
{abc:123} | .a<tab>
works, might seem supercomplex but it's a bit of a trick: it only works if the query to the left of the cursor is valid query (with some extra heuristics for indexing). Also bindings don't work well as they are generally in some scope, mostly useful for globals. - Supports sub-REPL:s via
... | repl
- inputs in the REPL "behaves" the same as the CLI, ex:
$ fq -i '1,2' number, ...[0:3][]> .*2 2 4 number, ...[0:2][]> .*2 | repl > number, ...[0:2][]> .*2 4 8 > number, ...[0:2][]> ^D number, ...[0:2][]> ^D $
- Has a
paste
functionnull> paste | repl abc <ctrl-d> > string> . "abc\n"
- Has a
slurp
/spew
function but i have to say i have nearly never used them, maybe if one could come up with some neater syntax that works well with jq.null> 1,2,3 | slurp("hello") null> $hello [ 1, 2, 3 ] null> spew("hello") 1 2 3
Things i would like to have:
- Multi-line edit of query
- Syntax highlight and checking
- Online documentation (at completion?)
from qq.
Thanks a lot for the advice and detailing some of the functionality/many features of fq
(big fan btw!), these suggestions would definitely be a major improvement and I look forward to taking a crack at some of them 👍
from qq.
Sorry, I definitely used the word "realtime" a bit too liberally in the readme. Very cool, will take a look and see if I can't hack something together w/ any of this when I have time if no one decides they want to work on abeforehand. If anyone wants to work on any component of the above mentioned, I am not too opinionated on implementation as long as it's approximates some of the above improvements @wader mentioned or the post @ here.#6 or any user interface improvements :)
from qq.
Related Issues (8)
- Can't go install because of `replace directives`? HOT 1
- `brew install qq` takes forever to get to just `0.03%` HOT 4
- Make Docker Build Multi Arch HOT 4
- Make Gron Input -> QQ Idempotent with Array Values HOT 1
- QQ shows version 0.15.0 when using 0.1.6 HOT 4
- Share HTML and XML modelling with mxj and fq? HOT 4
- Make GH Action and Instruction for use.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qq.