filhodanuvem / gitql

💊 A git query language

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

select * from commits

jcubic opened this issue · comments

This don't work:

git ql 'select * from commits order by date desc limit 2'

it return:

+-------+
|   *   |
+-------+
| <nil> |
+-------+
| <nil> |
+-------+

That is an interesting one, what do you think @jsixface?

I don't know golang but looking at the source it seems that both functions in runtime/commits.go need to share the list of fields maybe instead of metadataCommit function with switch something like javascript object with methods and then when field is "*" you could do something like javascript fields = Object.keys(data) don't know how do you do stuff like that in golang.

Yeah, I don't think that it will be hard to do. I will investigate that as soon as I have free time :)

This is not working ever without the limit and order by.
I'm looking into it now