tongo is a fast and keyboard-driven TUI (Terminal User Interface) for MongoDB.
Navigate and manipulate your data without leaving your terminal.
- Connect & save MongoDB connections
- Quickly navigate your data with customizable keybindings
- Filter your data using Mongo queries
- Create and edit documents using your terminal editor of choice
- Fuzzy search currently-visible data to quickly drill down to what you're looking for
- Run multiple sessions in tabs for quick data comparisons between collections
- Copy data directly to the system clipboard
- Browse your data in style with customizable color themes
Install Rust and Cargo, then install:
cargo install tongoInstall Nix, then clone this repo and install:
git clone git@github.com:drewzemke/tongo.git
cd tongo
nix-buildThen you can move the created binary somewhere on your path:
cp ./result/bin/tongo /usr/local/bin/tongoIf you're on Arch Linux, you can install tongo from the AUR:
paru -S tongoIf you're on macOS, install Homebrew and then run
brew install drewzemke/tap/tongo- Launch
tongoin your terminal of choice:
tongo- Start creating a new connection by pressing
A - Set a name for the connection and enter your database's connection string
- After connecting, select a database and then a connection to connect to
- Use the arrow keys to navigate through the data. Press
nandpto move between pages
At any time (except when inputting text), you can bring up a commands list by pressing ? that will explain what actions are available to you and what their keybindings are.
Load a connection directly:
tongo --url mongodb://localhost:27017 If you've previously stored a connection, you can load it by name:
tongo --connection localRestore your most-recently-closed session in the app:
tongo --lastThe first time you run tongo, a config.toml will be created for you in ~/.config/tongo on Mac and Linux and in <your-user-folder>\AppData\Roaming\tongo on Windows. (You can also see that file here.) It contains a full commented-out configuration together with descriptions of each configuration point.
tongo detects your terminal's background at startup and picks light- or dark-friendly default colors so the UI stays legible either way.
You can fully customize the colors used in tongo's UI to your liking by creating a theme.toml in the same directory as your configuration file; any colors you set there take precedence over the detected defaults. Check out our small themes collection for some examples to get you started.
Please open an issue if you run into a problem while using tongo, or if there's a piece of functionality you wish it had! You're also welcome to make changes yourself and open a PR.
