Metadata-Version: 2.1
Name: ketacli
Version: 0.17
Summary: KetaDB Client
Home-page: https://xishuhq.com
Author: lvheyang
Author-email: cuiwenzheng@ymail.com
License: MIT
Description-Content-Type: text/markdown
Requires-Dist: requests~=2.31.0
Requires-Dist: prettytable~=3.10.0
Requires-Dist: pyyaml~=6.0.1
Requires-Dist: mando~=0.7.1
Requires-Dist: argcomplete~=3.3.0
Requires-Dist: faker~=24.11.0
Requires-Dist: jinja2~=3.1.3
Requires-Dist: rich~=13.7.1

# ketadb 工具

## 示例

```shell
ketacli login --name <username> --endpoint http://localhost:9000 --token <yourtoken>

ketacli logout

# 枚举所有仪表盘
ketacli list dashboard --fields id,app,updateTime --sort updateTime --order asc --prefix test 

# 描述资源的字段
ketacli describe dashboard 

# 插入一条数据

ketacli insert --repo test01 '[{"a":1}]'

# 查询一条数据

ketacli search 'repo=test01 | limit 10' 

# 指定返回格式，支持json、csv、html、latex等

ketacli search 'repo=test01 | limit 10' --format json

#  创建一个资源

ketacli create repos test_repo --file file.json

# 删除一个资源
ketacli delete repos -n test_repo

# 查看可操作的资源列表
ketacli rs

# 查看具体资源操作方法
ketacli rs --type repos
```

## 自动补全

在你的 .bashrc / .zshrc 中加入以下语句

```shell
#zshrc 中不存在的话也需要添加
autoload -U +X bashcompinit && bashcompinit

eval "$(register-python-argcomplete ketacli)"
```
