|
1 | 1 | <img src="https://rawgit.com/gitql/gitql/master/gitql-logo.svg" alt="gitql" width="250"/>
|
2 | 2 |
|
3 |
| -[](https://travis-ci.org/gitql/gitql) [](https://codecov.io/gh/gitql/gitql) [](https://godoc.org/github.com/gitql/gitql) |
| 3 | +image:https://travis-ci.org/gitql/gitql.svg?branch=master[Build Status,link=https://travis-ci.org/gitql/gitql] image:https://codecov.io/gh/gitql/gitql/branch/master/graph/badge.svg[codecov,link=https://codecov.io/gh/gitql/gitql] image:https://godoc.org/github.com/gitql/gitql?status.svg[GoDoc,link=https://godoc.org/github.com/gitql/gitql] |
| 4 | + |
| 5 | +**gitql** is a SQL interface to Git repositories, written in Go. |
| 6 | + |
| 7 | +## Installation |
| 8 | + |
| 9 | +Check the [Releases](https://github.com/gitql/gitql/releases) page to download |
| 10 | +the gitql binary. |
| 11 | + |
| 12 | +## Usage |
| 13 | + |
| 14 | +``` |
| 15 | +Usage: |
| 16 | + gitql [OPTIONS] <query | version> |
| 17 | +
|
| 18 | +Help Options: |
| 19 | + -h, --help Show this help message |
| 20 | +
|
| 21 | +Available commands: |
| 22 | + query Execute a SQL query a repository. |
| 23 | + version Show the version information. |
| 24 | +``` |
| 25 | + |
| 26 | +For example: |
| 27 | + |
| 28 | +```bash |
| 29 | +$ cd my_git_repo |
| 30 | +$ gitql query 'SELECT hash, author_email, author_name FROM commits LIMIT 2;' |
| 31 | +SELECT hash, author_email, author_name FROM commits LIMIT 2; |
| 32 | ++------------------------------------------+--------------------+---------------+ |
| 33 | +| HASH | AUTHOR EMAIL | AUTHOR NAME | |
| 34 | ++------------------------------------------+--------------------+---------------+ |
| 35 | +| 02e0aa0ef807d2ae4d02ecdbe37681db9e812544 | Santiago M. Mola | [email protected] | |
| 36 | +| 034cb63f77f4a0d30d26dabb999d348be6640df7 | Antonio J. Navarro | [email protected] | |
| 37 | ++------------------------------------------+--------------------+---------------+ |
| 38 | +``` |
| 39 | + |
| 40 | +## Tables |
| 41 | + |
| 42 | +*TODO* |
| 43 | + |
| 44 | +## SQL syntax |
| 45 | + |
| 46 | +gitql supports a subset of the SQL standard, currently including: |
| 47 | + |
| 48 | +* `SELECT` |
| 49 | +* `WHERE` |
| 50 | +* `ORDER BY` (with `ASC` and `DESC`) |
| 51 | +* `LIMIT` |
| 52 | + |
| 53 | +## License |
| 54 | + |
| 55 | +gitql is licensed under the |
| 56 | +https://github.com/gitql/gitql/blob/master/LICENSE[MIT License]. |
0 commit comments