Skip to content

honhimW/ratisui

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ratisui

gif

Installation

Cargo

cargo install --git=https://github.com/honhimW/ratisui.git

Download

Currently, only linux_x86_64/linux_aarch64/macOS_aarch64/windows_x86_64 is automatically available.
If you need other platforms, you may try to build via GitHub Actions.
Please note that not all platforms can guarantee successful compilation and normal operation.

Github Release

Build from source

# clone repo
git clone https://github.com/honhimW/ratisui.git
# enter
cd ratisui
# build and run
cargo run

Quick Start

create a data source

  1. Press 's' (open server popup)
  2. Press 'c' (create data source)
  3. config data source
  4. Press 'Enter' for confirm
  5. select data source
  6. Press 'Esc' (close data source popup)
  7. Enjoy!

save configuration, auto save on exit

Data storage

User's data will be stored in ~/.config/ratisui/:

Application Configuration

// ~/.config/ratisui/config.ron
(
    fps: 45,                               // tui render fps limitation
    scan_size: 500,                        // redis key scan size,
    try_format: false,                     // fotmat raw data
    theme: Some("your-theme"),             // ~/.config/ratisui/theme/your-theme.ron
    history_size: 1000,                    // ~/.config/ratisui/cli.history
    cli_output_format: Redis,              // Redis(default) | Ron
    console_capacity: 2000,                // CLI output capacity, default as 3000
)

Databases Configuration

// ~/.config/ratisui/databases.ron
(
    default_database: Some("remote standalone"),
    databases: {
        "remote standalone": (
            host: "standalone.host",
            port: 6379,
            username: Some("foo"),
            password: Some("bar"),
            use_tls: false,
            use_ssh_tunnel: false,
            db: 0,
            protocol: RESP3,
        ),
        "remote cluster": (   // Cluster mode automatically detected
            host: "cluster.host",
            port: 6000,
            username: None,
            password: Some("password"),
            use_tls: false,
            use_ssh_tunnel: false,
            db: 0,
            protocol: RESP3,
        ),
    },
)

Themes Configuration

Note

See Theme template for more details.

// ~/.config/ratisui/theme/your-theme.ron
(
    kind: Dark,
    toast: (
        info: Tailwind(GREEN, C700),
        warn: Yellow,
        error: Rgb(255, 0, 0),
    ),
)

Features

Connection mode

  • standalone mode
  • cluster mode

Data Type

  • String
  • List
  • Set
  • Sorted Set
  • Hash
  • Stream
  • ReJson

Explorer

  • Key scan (Fuzzy/Pattern)
  • Keys tree
  • Key create, rename, delete
  • Async query & render
  • Highlight & format for raw data
  • Table view for list, set, sorted set, hash, stream
  • RedisSearch, completion for indexes/FT.SEARCH

Command line tool

  • Auto Completion
  • Command history
  • Command execution
  • Monitor/(P)Subscribe listening
  • Output format

Misc

  • Logger viewer(TuiLogger)
  • Non-blocking command execution
  • Configuration persistence
  • Use SSH tunnel(russh)
  • Connection pool(deadpool-redis)
  • Configurable theme

TODO

  • nothing to do...🤔