rainfrog
A terminal-based tool for querying and browsing PostgreSQL, MySQL, SQLite, DuckDB and other databases with vim-like keybindings.
Tested on LinuxKnown vulnerabilities
Use it
Before you install: known vulnerabilities
pickfit found 2 known high or critical vulnerabilities (4 findings, one per affected package version) in the packages a fresh install brings (OSV.dev, 16 Nov 2026). Weigh this before you install it.
crates:quick-xml 0.37.5Quadratic run time when checking a start tag for duplicate attribute names (RUSTSEC-2026-0194, high, fixed in 0.41.0)
See 3 more
crates:quick-xml 0.38.3— RUSTSEC-2026-0194 (high), fixed in 0.41.0crates:quick-xml 0.37.5— RUSTSEC-2026-0195 (high), fixed in 0.41.0crates:quick-xml 0.38.3— RUSTSEC-2026-0195 (high), fixed in 0.41.0
Linux x86_64
You need first
- System packages:
Oracle Client libraries (for the oracle driver),jq and fzf (for the install script)
setup 1, setup 2 still names /home/sbx inside single quotes, where $HOME would not work: put your own home folder there before running it.
These steps ran from a folder named work in the home folder, which already existed. Make it and run them from there:
mkdir -p "$HOME/work" && cd "$HOME/work"download v0.4.7 x86_64-unknown-linux-gnu release tarball + sha256, verify, unpack to ~/.local and link into ~/.local/bin (same steps as install.sh)
set -e; B=rainfrog-v0.4.7-x86_64-unknown-linux-gnu; U=https://github.com/achristmascarl/rainfrog/releases/download/v0.4.7; mkdir -p ~/tmp/rf ~/.local/bin && cd ~/tmp/rf && curl -fsSL -o $B.tar.gz $U/$B.tar.gz && curl -fsSL -o $B.sha256 $U/$B.sha256 && sha256sum -c $B.sha256 && tar -xzf $B.tar.gz -C ~/.local/ && ln -sf ~/.local/rainfrog ~/.local/bin/rainfrog
Verified in pickfit: the commands exactly as its sandbox ran them
For the record only: they name the sandbox's home, /home/sbx.
set -e; B=rainfrog-v0.4.7-x86_64-unknown-linux-gnu; U=https://github.com/achristmascarl/rainfrog/releases/download/v0.4.7; mkdir -p ~/tmp/rf ~/.local/bin && cd ~/tmp/rf && curl -fsSL -o $B.tar.gz $U/$B.tar.gz && curl -fsSL -o $B.sha256 $U/$B.sha256 && sha256sum -c $B.sha256 && tar -xzf $B.tar.gz -C ~/.local/ && ln -sf ~/.local/rainfrog ~/.local/bin/rainfrograinfrog --versionpip install --user pyte && python3 - <<'EOF'
import sqlite3
c=sqlite3.connect('/home/sbx/work/test.db')
c.executescript("""
create table users(id integer primary key, name text, email text);
insert into users values (1,'alice','alice@example.com'),(2,'bob','bob@example.com'),(3,'carol','carol@example.com');
create table orders(id integer primary key, user_id integer, item text);
insert into orders values (1,1,'frogspawn'),(2,2,'lilypad');
""")
c.commit()
EOF
cat > /home/sbx/work/drive.py <<'EOF'
import os, pty, sys, time, json, select, pyte
# usage: drive.py '<json list of actions>' actions: ["s", text] send, ["w", secs] wait, ["d", label] dump screen
acts = json.loads(sys.argv[1])
cols, rows = 160, 45
screen = pyte.Screen(cols, rows); stream = pyte.ByteStream(screen)
pid, fd = pty.fork()
if pid == 0:
os.environ['TERM'] = 'xterm-256color'
os.environ['COLUMNS'] = str(cols); os.environ['LINES'] = str(rows)
os.execvp('rainfrog', ['rainfrog', '--url', 'sqlite:///home/sbx/work/test.db'])
import fcntl, termios, struct
fcntl.ioctl(fd, termios.TIOCSWINSZ, struct.pack('HHHH', rows, cols, 0, 0))
def pump(t):
end = time.time() + t
while time.time() < end:
r, _, _ = select.select([fd], [], [], 0.05)
if r:
try: data = os.read(fd, 65536)
except OSError: return
stream.feed(data)
# answer cursor position queries
if b'\x1b[6n' in data: os.write(fd, b'\x1b[1;1R')
pump(3)
for a in acts:
if a[0] == 's': os.write(fd, a[1].encode()); pump(0.6)
elif a[0] == 'w': pump(a[1])
elif a[0] == 'd':
print('===== SCREEN:', a[1], '=====')
for line in screen.display:
if line.strip(): print(line.rstrip())
os.write(fd, b'\x03'); pump(1)
try: os.kill(pid, 9)
except Exception: pass
EOFpython3 - <<'EOF'
p='/home/sbx/work/drive.py'; s=open(p).read()
s=s.replace("if line.strip(): print(line.rstrip())","t=' '.join(line.translate(str.maketrans('','','│█─┌┐└┘▀↑↓←→')).split())\n if t: print(t)")
open(p,'w').write(s)
EOF
python3 /home/sbx/work/drive.py '[["d","start"]]'python3 drive.py '[["s","\u000b"],["s","j"],["s","k"],["s","G"],["s","\r"],["w",2],["d","after G + Enter on users"]]'Check that it works
rainfrog --versionThe output should contain “rainfrog 0.4.7”.
First thing to try
pip install --user pyte && python3 - <<'EOF'
import sqlite3
c=sqlite3.connect('/home/sbx/work/test.db')
c.executescript("""
create table users(id integer primary key, name text, email text);
insert into users values (1,'alice','alice@example.com'),(2,'bob','bob@example.com'),(3,'carol','carol@example.com');
create table orders(id integer primary key, user_id integer, item text);
insert into orders values (1,1,'frogspawn'),(2,2,'lilypad');
""")
c.commit()
EOF
cat > /home/sbx/work/drive.py <<'EOF'
import os, pty, sys, time, json, select, pyte
# usage: drive.py '<json list of actions>' actions: ["s", text] send, ["w", secs] wait, ["d", label] dump screen
acts = json.loads(sys.argv[1])
cols, rows = 160, 45
screen = pyte.Screen(cols, rows); stream = pyte.ByteStream(screen)
pid, fd = pty.fork()
if pid == 0:
os.environ['TERM'] = 'xterm-256color'
os.environ['COLUMNS'] = str(cols); os.environ['LINES'] = str(rows)
os.execvp('rainfrog', ['rainfrog', '--url', 'sqlite:///home/sbx/work/test.db'])
import fcntl, termios, struct
fcntl.ioctl(fd, termios.TIOCSWINSZ, struct.pack('HHHH', rows, cols, 0, 0))
def pump(t):
end = time.time() + t
while time.time() < end:
r, _, _ = select.select([fd], [], [], 0.05)
if r:
try: data = os.read(fd, 65536)
except OSError: return
stream.feed(data)
# answer cursor position queries
if b'\x1b[6n' in data: os.write(fd, b'\x1b[1;1R')
pump(3)
for a in acts:
if a[0] == 's': os.write(fd, a[1].encode()); pump(0.6)
elif a[0] == 'w': pump(a[1])
elif a[0] == 'd':
print('===== SCREEN:', a[1], '=====')
for line in screen.display:
if line.strip(): print(line.rstrip())
os.write(fd, b'\x03'); pump(1)
try: os.kill(pid, 9)
except Exception: pass
EOFpython3 - <<'EOF'
p='/home/sbx/work/drive.py'; s=open(p).read()
s=s.replace("if line.strip(): print(line.rstrip())","t=' '.join(line.translate(str.maketrans('','','│█─┌┐└┘▀↑↓←→')).split())\n if t: print(t)")
open(p,'w').write(s)
EOF
python3 /home/sbx/work/drive.py '[["d","start"]]'python3 drive.py '[["s","\u000b"],["s","j"],["s","k"],["s","G"],["s","\r"],["w",2],["d","after G + Enter on users"]]'Run rainfrog --url <database-url> (for example rainfrog --url sqlite://<file>) to open the menu of tables next to the query editor.
What it does
- Move around with vim-style keys and the mouseTested
How to use it
- Press Ctrl+k to focus the table list.
- Use
jandkto move down and up, andGto jump to the last table. - Press Enter on a table to load a preview of its rows.
- Write SQL queries and reuse them from history or favoritesTested
How to use it
- Press Alt+2 to open the query editor, press
iand type your query, then press Esc and F5 to run it. - Press Alt+f, type a name and press Enter to save the query as a favorite.
- Press Alt+4 to see query history and Alt+5 to see favorites.
- Press Alt+2 to open the query editor, press
- Copy data, filter tables and switch schemasTested
How to use it
- Press Ctrl+k to focus the table list.
- Press
/, type part of a table name and press Enter to filter the list.
- View table details such as columns and indexesTested
How to use it
- Press Ctrl+k and select a table in the list.
- Press
1to show its columns or3to show its indexes.
How far pickfit got
Linux x86_64
- Installs
- Starts
- 4 of 4 features work
- Works offline
macOS and Windows: the project says it runs there; pickfit hasn’t tried it.
Good for
- browse schemas and preview tables of a Postgres database in the terminal
- export query results to CSV
- save frequently used SQL queries as favorites
How pickfit tested it
Each run starts from a clean machine and follows the steps above. How pickfit verifies
Linux x86_64
Its main function works
- Replayed from scratch
- Works offline
- Checked on 15 Nov 2026
- Version 0.4.7-2c7b5e6
Differences the test machine hit
- README: curl -LSsf .../install.sh | bash (needs jq and fzf)
In the test: jq and fzf are absent, and the script picks the binary interactively with fzf, so it cannot run unattended; the README's 'release page binaries' path (download the x86_64-unknown-linux-gnu tarball, check sha256, unpack, link into ~/.local/bin) was used instead - README: script needs jq and fzf installed to run
In the test: the script's need_cmd only prints a warning and continues when a command is missing, so a user without jq or fzf gets confusing later failures - README: terminal UI usage
In the test: non-interactive testing needed a pty driver (python pty + pyte, pip install --user pyte) to send keystrokes and render the screen