{ "info": { "author": "athenacli Core Team", "author_email": "athenacli@googlegroups.com", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: Unix", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: SQL", "Topic :: Database", "Topic :: Database :: Front-Ends", "Topic :: Software Development", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "[![Build Status](https://travis-ci.org/dbcli/athenacli.svg?branch=master)](https://travis-ci.org/dbcli/athenacli)\n[![PyPI](https://img.shields.io/pypi/v/athenacli.svg)](https://pypi.python.org/pypi/athenacli)\n[![image](https://img.shields.io/pypi/l/athenacli.svg)](https://pypi.org/project/athenacli/)\n[![image](https://img.shields.io/pypi/pyversions/athenacli.svg)](https://pypi.org/project/athenacli/)\n[![Join the chat at https://gitter.im/dbcli/athenacli](https://badges.gitter.im/dbcli/athenacli.svg)](https://gitter.im/dbcli/athenacli?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)\n[![image](https://img.shields.io/badge/Say%20Thanks-!-1EAEDB.svg)](https://saythanks.io/to/zzl0)\n\n# Introduction\n\nAthenaCLI is a command line interface (CLI) for the [Athena](https://aws.amazon.com/athena/) service that can do auto-completion and syntax highlighting, and is a proud member of the dbcli community.\n\n![](./docs/_static/gif/athenacli.gif)\n\n# Quick Start\n\n## Install\n\nIf you already know how to install python packages, then you can simply do:\n\n``` bash\n$ pip install athenacli\n```\n\nIf you don't know how to install python packages, please check the [Install](./docs/install.rst) page for more options (e.g brew, docker)\n\n## Config\n\nA config file is automatically created at `~/.athenacli/athenaclirc` at first launch (run athenacli). See the file itself for a description of all available options.\n\nBelow 4 variables are required. If you are a user of aws cli, you can refer to [awsconfig](./docs/awsconfig.rst) file to see how to reuse credentials configuration of aws cli.\n\n``` text\n# AWS credentials\naws_access_key_id = ''\naws_secret_access_key = ''\nregion = '' # e.g us-west-2, us-east-1\n\n# Amazon S3 staging directory where query results are stored.\n# NOTE: S3 should in the same region as specified above.\n# The format is 's3://'\ns3_staging_dir = ''\n```\n\nor you can also use environment variables:\n\n``` bash\n$ export AWS_ACCESS_KEY_ID=YOUR_ACCESS_KEY_ID\n$ export AWS_SECRET_ACCESS_KEY=YOUR_SECRET_ACCESS_KEY\n$ export AWS_DEFAULT_REGION=us-west-2\n$ export AWS_ATHENA_S3_STAGING_DIR=s3://YOUR_S3_BUCKET/path/to/\n```\n\n## Create a table\n\n``` bash\n$ athenacli -e examples/create_table.sql\n```\n\nYou can find `examples/create_table.sql` [here](./examples/create_table.sql).\n\n## Run a query\n\n``` bash\n$ athenacli -e 'select elb_name, request_ip from elb_logs LIMIT 10'\n```\n\n## REPL\n\n``` bash\n$ athenacli []\n```\n\n# Features\n\n- Auto-completes as you type for SQL keywords as well as tables and columns in the database.\n- Syntax highlighting.\n- Smart-completion will suggest context-sensitive completion.\n - `SELECT * FROM ` will only show table names.\n - `SELECT * FROM users WHERE ` will only show column names.\n- Pretty prints tabular data and various table formats.\n- Some special commands. e.g. Favorite queries.\n- Alias support. Column completions will work even when table names are aliased.\n\nPlease refer to the [Features](./docs/features.rst) page for the screenshots of above features.\n\n# Usages\n\n```bash\n$ athenacli --help\nUsage: main.py [OPTIONS] [DATABASE]\n\nA Athena terminal client with auto-completion and syntax highlighting.\n\nExamples:\n - athenacli\n - athenacli my_database\n\nOptions:\n-e, --execute TEXT Execute a command (or a file) and quit.\n-r, --region TEXT AWS region.\n--aws-access-key-id TEXT AWS access key id.\n--aws-secret-access-key TEXT AWS secretaccess key.\n--s3-staging-dir TEXT Amazon S3 staging directory where query\n results are stored.\n--athenaclirc PATH Location of athenaclirc file.\n--help Show this message and exit.\n```\n\nPlease go to the [Usages](https://athenacli.readthedocs.io/en/latest/usage.html) for detailed information on how to use AthenaCLI.\n\n# Contributions\n\nIf you're interested in contributing to this project, first of all I would like to extend my heartfelt gratitude. I've written a small [doc](https://athenacli.readthedocs.io/en/latest/develop.html) to describe how to get this running in a development setup.\n\nPlease feel free to reach out to me if you need help. My email: zhuzhaolong0 AT gmail com\n\n# FAQs\n\nPlease refer to the [FAQs](https://athenacli.readthedocs.io/en/latest/faq.html) for other information, e.g. \"How can I get support for athenacli?\".\n\n# Credits\n\nA special thanks to [Amjith Ramanujam](https://github.com/amjith) for creating pgcli and mycli, which inspired me to create this AthenaCLI, and AthenaCLI is created based on a clone of mycli.\n\nThanks to [Jonathan Slenders](https://github.com/jonathanslenders) for creating the [Python Prompt Toolkit](https://github.com/jonathanslenders/python-prompt-toolkit), which leads me to pgcli and mycli. It's a lot of fun playing with this library.\n\nThanks to [PyAthena](https://github.com/laughingman7743/PyAthena) for a pure python adapter to Athena database.\n\nLast but not least, thanks my team and manager encourage me to work on this hobby project.\n\n# Similar projects\n\n- [guardian/athena-cli](https://github.com/guardian/athena-cli): Presto-like CLI tool for AWS Athena.\n- [pengwynn/athena-cli](https://github.com/pengwynn/athena-cli): CLI for Amazon Athena, powered by JRuby.\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/dbcli/athenacli", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "athenacli", "package_url": "https://pypi.org/project/athenacli/", "platform": "", "project_url": "https://pypi.org/project/athenacli/", "project_urls": { "Homepage": "https://github.com/dbcli/athenacli" }, "release_url": "https://pypi.org/project/athenacli/0.1.4/", "requires_dist": [ "click (>=4.1)", "Pygments (>=1.6)", "prompt-toolkit (<1.1.0,>=1.0.10)", "sqlparse (<0.3.0,>=0.2.2)", "configobj (>=5.0.5)", "cli-helpers[styles] (>=1.0.1)", "botocore (>=1.5.52)", "boto3 (>=1.4.4)", "PyAthena (>=1.2.2)" ], "requires_python": "", "summary": "CLI for Athena Database. With auto-completion and syntax highlighting.", "version": "0.1.4" }, "last_serial": 4491950, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "0c17ec42d153709ac7d6cd6f856bd10e", "sha256": "1a337d6384a6cb351f1aa6f7b645da454095f344db8ce0c7bf4757631d7176e1" }, "downloads": -1, "filename": "athenacli-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "0c17ec42d153709ac7d6cd6f856bd10e", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 43250, "upload_time": "2018-09-20T07:51:03", "url": "https://files.pythonhosted.org/packages/5a/05/169661340c7533738847003d18572d40b10bbcc84b5886bfaa55af3a0b8a/athenacli-0.1.0-py2.py3-none-any.whl" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "c51fbabaeeb71bfea007f160fe743a55", "sha256": "c050ba98d5158758b62aa8561fdeb1c4e7934e153456fc02432856316822db6a" }, "downloads": -1, "filename": "athenacli-0.1.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c51fbabaeeb71bfea007f160fe743a55", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 43260, "upload_time": "2018-09-24T00:15:37", "url": "https://files.pythonhosted.org/packages/d9/3d/8a163328558aa6758ad6018ccc9e98c2d56050510ee7b126eca43b79f0bb/athenacli-0.1.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "38150edd699ab7685501a2c80b92ca19", "sha256": "108254117a1da78f0c80a9ae4dc1a10fbaeb1ee8a29d4ca2ef1024ff85a50742" }, "downloads": -1, "filename": "athenacli-0.1.1.tar.gz", "has_sig": false, "md5_digest": "38150edd699ab7685501a2c80b92ca19", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 38025, "upload_time": "2018-09-24T00:15:39", "url": "https://files.pythonhosted.org/packages/6f/fd/2cced0aa8d6fb79b74527282d982059e0639a8648598dfbd5762ca010bc1/athenacli-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "607cde47cf822cd34150dd12756ad039", "sha256": "0395fc408357f31449bc22167e9240b71558424b0b13c4b4559fcda6a6ed7967" }, "downloads": -1, "filename": "athenacli-0.1.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "607cde47cf822cd34150dd12756ad039", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 45033, "upload_time": "2018-10-06T15:36:34", "url": "https://files.pythonhosted.org/packages/66/4b/324cff41b0b1e614d1b87a1f756e6de7d35d51593c4df3301e0851cb47b0/athenacli-0.1.2-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "8da3d42cf8ce793d366fbb036fa185f6", "sha256": "5e8f2b96617e5814165a78c7ae6644b9bec800df008ac6bfa3d154c40dd94b42" }, "downloads": -1, "filename": "athenacli-0.1.2.tar.gz", "has_sig": false, "md5_digest": "8da3d42cf8ce793d366fbb036fa185f6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 38181, "upload_time": "2018-10-06T15:36:36", "url": "https://files.pythonhosted.org/packages/87/8f/a7c888353c6e1f5097f2d27a2cc020b117bc1eb86b2c7ea4dc95b3a859ca/athenacli-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "0f502800c16b0861782cc440e773ae79", "sha256": "02174ae63995f16ed2e59ac9c0f75a46b3ca79750d5893455a38ff91d528222e" }, "downloads": -1, "filename": "athenacli-0.1.3-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "0f502800c16b0861782cc440e773ae79", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 46907, "upload_time": "2018-10-16T05:14:42", "url": "https://files.pythonhosted.org/packages/cd/b1/15d38fd6af41b8b83a2eeee90d5b0ab8c9112d75248afaf413711e7b23fc/athenacli-0.1.3-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "512eca6be2b4cc6763a1e76ef583b5f4", "sha256": "8d818b10362f95787e3ffbc347d35432bc2ce0c2f11e6fafddfc70a1a8258219" }, "downloads": -1, "filename": "athenacli-0.1.3.tar.gz", "has_sig": false, "md5_digest": "512eca6be2b4cc6763a1e76ef583b5f4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41419, "upload_time": "2018-10-16T05:14:44", "url": "https://files.pythonhosted.org/packages/c5/b2/44b7207adc8f0cb5c3a641fb7398f5d87cee332f40be28a63463a397dec1/athenacli-0.1.3.tar.gz" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "529e5426185b8fafb548813a0a68893f", "sha256": "2aad201c1b049af2a3bfe4a5b881231ce285b805c787675b3e99eb18b174c229" }, "downloads": -1, "filename": "athenacli-0.1.4-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "529e5426185b8fafb548813a0a68893f", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 46900, "upload_time": "2018-11-16T01:07:15", "url": "https://files.pythonhosted.org/packages/88/30/5bd986722111d4f0e8f55efe0445dfa2d1f3fcf8ba2525de71eacf6d998b/athenacli-0.1.4-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c289cc52c1dbfe0451c5f6f285271952", "sha256": "d9a4d464496fdc06abe380c28afb1cd56cb88a1ca8f9d92ab74f4f43214009a3" }, "downloads": -1, "filename": "athenacli-0.1.4.tar.gz", "has_sig": false, "md5_digest": "c289cc52c1dbfe0451c5f6f285271952", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41444, "upload_time": "2018-11-16T01:07:18", "url": "https://files.pythonhosted.org/packages/2e/10/c58dcc469a8889efdcc332e5bff0739bc9c4bae801becc7de140d3682b81/athenacli-0.1.4.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "529e5426185b8fafb548813a0a68893f", "sha256": "2aad201c1b049af2a3bfe4a5b881231ce285b805c787675b3e99eb18b174c229" }, "downloads": -1, "filename": "athenacli-0.1.4-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "529e5426185b8fafb548813a0a68893f", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 46900, "upload_time": "2018-11-16T01:07:15", "url": "https://files.pythonhosted.org/packages/88/30/5bd986722111d4f0e8f55efe0445dfa2d1f3fcf8ba2525de71eacf6d998b/athenacli-0.1.4-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "c289cc52c1dbfe0451c5f6f285271952", "sha256": "d9a4d464496fdc06abe380c28afb1cd56cb88a1ca8f9d92ab74f4f43214009a3" }, "downloads": -1, "filename": "athenacli-0.1.4.tar.gz", "has_sig": false, "md5_digest": "c289cc52c1dbfe0451c5f6f285271952", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 41444, "upload_time": "2018-11-16T01:07:18", "url": "https://files.pythonhosted.org/packages/2e/10/c58dcc469a8889efdcc332e5bff0739bc9c4bae801becc7de140d3682b81/athenacli-0.1.4.tar.gz" } ] }