https://github.com/takashabe/btcli
btcli is a CLI client for the Bigtable. Has many read options and auto-completion.
https://github.com/takashabe/btcli
bigtable cli gcp go golang google-cloud-platform
Last synced: 4 months ago
JSON representation
btcli is a CLI client for the Bigtable. Has many read options and auto-completion.
- Host: GitHub
- URL: https://github.com/takashabe/btcli
- Owner: takashabe
- License: mit
- Created: 2018-03-14T07:15:19.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-02-25T02:01:25.000Z (over 3 years ago)
- Last Synced: 2024-11-18T12:46:35.349Z (over 1 year ago)
- Topics: bigtable, cli, gcp, go, golang, google-cloud-platform
- Language: Go
- Homepage:
- Size: 141 KB
- Stars: 20
- Watchers: 3
- Forks: 3
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-bigtable - btcli - CLI client for the Bigtable with auto-completion. (Tools / Command-line)
README
[](https://godoc.org/github.com/takashabe/btcli)
[](https://circleci.com/gh/takashabe/btcli)
[](https://goreportcard.com/report/github.com/takashabe/btcli)
# btcli
btcli is a CLI client for the Bigtable. Has many read options and auto-completion.

## Features
btcli is the cloud bigtable client tool. Connect to your bigtable instances and any read items with auto-completion.
_write commands are not implemented yet_
### Compare to cbt
`cbt` is an official bigtable client tool
- btcli has auto-completion
- btcli can decode a big-endian values
- btcli has a filter for `value`, `version` and `family`
- A print format that same as the cbt
## Installation
```sh
go get -u github.com/takashabe/btcli/cmd/btcli
```
_Require go1.11 or later and GO111MODULE environemnts_
## Usage
### Connect to bigtable
```sh
btcli -project -instance -creds
```
_-creds e.g. `~/.config/gcloud/application_default_credentials.json`_
### Subcommand and options
- ls
List tables
```
ls List tables
```
- count
Count rows in a table
```
count
```
- lookup
Read from a single row
```
lookup [family=] [version=]
version Read only latest columns
decode Decode big-endian value
decode-columns Decode big-endian value with columns. [,]
```
- read
Read rows
```
read [start=] [end=] [prefix=] [family=] [version=]
start Start reading at this row
end Stop reading before this row
prefix Read rows with this prefix
value Read rows with has value
family Read only columns family with
version Read only latest columns
from Read cells whose version is newer than or equal to this unixtime
to Read cells whose version is older than this unixtime
decode Decode big-endian value
decode-columns Decode big-endian value with columns. [,]
```
### Environments
| Env | Detail |
| --- | --- |
| BTCLI_DECODE_TYPE | set the default decoding type.
values: `string, int, float` |
## Support commands
### Read commands
- [x] ls
- [x] count
- [x] lookup
- [x] version
- [x] decode
- [x] decode-columns
- [x] read
- [x] start
- [x] end
- [x] prefix
- [x] value
- [x] family
- [x] version
- [x] from
- [x] to
- [x] decode
- [x] decode-columns
### Write commands
- [ ] createfamily
- [ ] createtable
- [ ] deletecolumn
- [ ] deletefamily
- [ ] deleterow
- [ ] deletetable
- [ ] set
- [ ] setgcpolicy
### Others
- [x] help