{"id":13796715,"url":"https://github.com/sqle/gitquery","last_synced_at":"2026-01-12T00:46:12.967Z","repository":{"id":65417245,"uuid":"122985853","full_name":"sqle/gitquery","owner":"sqle","description":"[DEPRECATED] See https://github.com/src-d/gitbase","archived":false,"fork":false,"pushed_at":"2018-02-26T15:07:44.000Z","size":1560,"stargazers_count":15,"open_issues_count":0,"forks_count":2,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-02-14T22:35:06.039Z","etag":null,"topics":["git","golang","sql","sql-interface"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sqle.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-02-26T15:03:02.000Z","updated_at":"2023-07-14T15:42:30.000Z","dependencies_parsed_at":"2023-01-22T14:45:17.474Z","dependency_job_id":null,"html_url":"https://github.com/sqle/gitquery","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqle%2Fgitquery","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqle%2Fgitquery/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqle%2Fgitquery/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqle%2Fgitquery/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sqle","download_url":"https://codeload.github.com/sqle/gitquery/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225159877,"owners_count":17430202,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["git","golang","sql","sql-interface"],"created_at":"2024-08-03T23:01:14.143Z","updated_at":"2026-01-12T00:46:12.961Z","avatar_url":"https://github.com/sqle.png","language":"Go","readme":"# GitQuery  \u003ca href=\"https://codebeat.co/projects/github-com-sqle-gitql\"\u003e\u003cimg alt=\"codebeat badge\" src=\"https://codebeat.co/badges/d797a013-326b-4686-a1a7-adcb3039f65c\" /\u003e\u003c/a\u003e \u003ca href=\"https://travis-ci.org/sqle/gitquery\"\u003e\u003cimg alt=\"Build Status\" src=\"https://travis-ci.org/sqle/gitquery.svg?branch=master\" /\u003e\u003c/a\u003e \u003ca href=\"https://codecov.io/gh/sqle/gitquery\"\u003e\u003cimg alt=\"codecov\" src=\"https://codecov.io/gh/sqle/gitquery/branch/master/graph/badge.svg\" /\u003e\u003c/a\u003e \u003ca href=\"https://godoc.org/gopkg.in/sqle/gitquery.v0\"\u003e\u003cimg alt=\"GoDoc\" src=\"https://godoc.org/gopkg.in/sqle/gitquery.v0?status.svg\" /\u003e\u003c/a\u003e\n\n\u003cdiv style=\"text-align:center\"\u003e\u003cimg src =\"assets/tty.gif\"/\u003e\u003c/div\u003e\n\n## Installation\n\nCheck the [Releases](https://github.com/sqle/gitquery/releases) page to download\nthe gitquery binary.\n\n## Usage\n\n```bash\nUsage:\n  gitquery [OPTIONS] \u003cquery | shell | version\u003e\n\nHelp Options:\n  -h, --help  Show this help message\n\nAvailable commands:\n  query    Execute a SQL query a repository.\n  shell    Start an interactive session.\n  version  Show the version information.\n```\n\nFor example:\n\n```bash\n$ cd my_git_repo\n$ gitquery query 'SELECT hash, author_email, author_name FROM commits LIMIT 2;' \nSELECT hash, author_email, author_name FROM commits LIMIT 2;\n+------------------------------------------+---------------------+-----------------------+\n|                   HASH                   |    AUTHOR EMAIL     |      AUTHOR NAME      |\n+------------------------------------------+---------------------+-----------------------+\n| 003dc36e0067b25333cb5d3a5ccc31fd028a1c83 | user1@test.io       | Santiago M. Mola      |\n| 01ace9e4d144aaeb50eb630fed993375609bcf55 | user2@test.io       | Antonio Navarro Perez |\n+------------------------------------------+---------------------+-----------------------+\n```\n\nYou can use the interactive shell like you usually do to explore tables in postgreSQL per example:\n\n```bash\n$ gitquery shell\n\n           gitQL SHELL\n           -----------\nYou must end your queries with ';'\n\n!\u003e SELECT hash, author_email, author_name FROM commits LIMIT 2;\n\n--\u003e Executing query: SELECT hash, author_email, author_name FROM commits LIMIT 2;\n\n+------------------------------------------+---------------------+-----------------------+\n|                   HASH                   |    AUTHOR EMAIL     |      AUTHOR NAME      |\n+------------------------------------------+---------------------+-----------------------+\n| 003dc36e0067b25333cb5d3a5ccc31fd028a1c83 | user1@test.io       | Santiago M. Mola      |\n| 01ace9e4d144aaeb50eb630fed993375609bcf55 | user2@test.io       | Antonio Navarro Perez |\n+------------------------------------------+---------------------+-----------------------+\n!\u003e  \n```\n\n## Tables\n\ngitquery exposes the following tables:\n\n|     Name     |                                               Columns                                               |\n|:------------:|:---------------------------------------------------------------------------------------------------:|\n|    commits   | hash, author_name, author_email, author_time, comitter_name, comitter_email, comitter_time, message |\n|     blobs    | hash, size                                                                                          |\n|  refs        | name, type, hash, target, is_branch, is_note, is_remote, is_tag                                     |\n|     tags     | hash, name, tagger_email, tagger_name, tagger_when, message, target                                 |\n| tree_entries | tree_hash, entry_hash, mode, name                                                                   |\n\n## SQL syntax\n\nWe are continuously adding more functionality to gitquery. We support a subset of the SQL standard, currently including:\n\n|                        |                                     Supported                                     |\n|:----------------------:|:---------------------------------------------------------------------------------:|\n| Comparison expressions |                                !=, ==, \u003e, \u003c, \u003e=,\u003c=                                |\n|  Grouping expressions  |                                    COUNT, FIRST                                   |\n|  Standard expressions  |                              ALIAS, LITERAL, STAR (*)                             |\n|       Statements       | CROSS JOIN, DESCRIBE, FILTER (WHERE), GROUP BY, LIMIT, SELECT, SHOW TABLES, SORT  |\n\n## License\n\ngitquery is licensed under the [MIT License](https://github.com/sqle/gitquery/blob/master/LICENSE).\n","funding_links":[],"categories":["Git and Version Control Systems"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsqle%2Fgitquery","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsqle%2Fgitquery","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsqle%2Fgitquery/lists"}