Git Product home page Git Product logo

bolter's Introduction

bolter

View BoltDB file in your terminal

List all items

Install

$ go get -u github.com/hasit/bolter

Usage

$ bolter [global options]

GLOBAL OPTIONS:
  --file FILE, -f FILE        boltdb FILE to view
  --bucket BUCKET, -b BUCKET  boltdb BUCKET to view
  --machine, -m               key=value format
  --help, -h                  show help
  --version, -v               print the version

List all buckets

$ bolter -f emails.db
+---------------------------+
|          BUCKETS          |
+---------------------------+
| [email protected]              |
| [email protected]              |
| [email protected]        |
| [email protected]             |
+---------------------------+

List all items in bucket

$ bolter -f emails.db -b [email protected]
Bucket: [email protected]
+---------------+---------------------+
|      KEY      |        VALUE        |
+---------------+---------------------+
| emailLastSent |                     |
| subLocation   |                     |
| subTag        |                     |
| userActive    | true                |
| userCreatedOn | 2016-10-28 07:21:49 |
| userEmail     | [email protected]        |
| userFirstName | John                |
| userLastName  | Doe                 |
+---------------+---------------------+

Nested buckets

You can easily list all items in a nested bucket:

$ bolter -f my.db
+-----------+
|  BUCKETS  |
+-----------+
|   root    |
+-----------+

$ bolter -f my.db -b root
Bucket: root
+---------+---------+
|   KEY   |  VALUE  |
+---------+---------+
| nested* |         |
+---------+---------+

* means the key ('nested' in this case) is a bucket.

$ bolter -f my.db -b root.nested
Bucket: root.nested
+---------+---------+
|   KEY   |  VALUE  |
+---------+---------+
|  mykey  | myvalue |
+---------+---------+

Machine friendly output

$ bolter -f emails.db -m
[email protected]
[email protected]
[email protected]
[email protected]

$ bolter -f emails.db -b [email protected] -m
emailLastSent=
subLocation=
subTag=
userActive=true
userCreatedOn=2016-10-28 07:21:49
[email protected]
userFirstName=John
userLastName=Doe
nested-bucket*=

Contribute

Feel free to ask questions, post issues and open pull requests. My only requirement is that you run gofmt on your code before you send in a PR.

bolter's People

Contributors

fumin avatar hasit avatar jinleileiking avatar ross-spencer avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.