pgcli
Pgcli is a command line interface for Postgres with auto-completion and syntax highlighting.
Solution alternative à psql.
Journaux liées à cette note :
Journal du vendredi 10 avril 2026 à 10:21
Dans Postgres Weekly numéro 643 #JaiDécouvert rpg :
rpg — modern Postgres terminal written in Rust. psql-compatible, with built-in DBA diagnostics and AI assistant
La liste des fonctionnalités de rpg me donne envie de le tester pour voir si, à l'usage, il est une bonne alternative à psql, pgcli ou usql.
Features
- psql-compatible —
\-commands are standard psql meta-commands (\d,\dt,\copy,\watch, ...);/-commands are rpg extensions — both AI and non-AI. Same muscle memory, clearly distinct additions.- Active Session History —
/ashlive wait event timeline with drill-down; pg_ash history integration- AI assistant —
/ask,/fix,/explain,/optimize,/text2sql,/yolo- DBA diagnostics — 15+
/dbacommands: activity, locks, bloat, indexes, vacuum, replication, config- Schema-aware completion — tab completion for tables, columns, functions, keywords
- Lua plugin system — extend rpg with custom
/-commands written in Lua- TUI pager — scrollable pager for large result sets
- Syntax highlighting — SQL keywords, strings, operators; EXPLAIN plans; color-coded errors/warnings
- Markdown output —
\pset format markdownfor docs-ready table output- Named queries — save and recall frequent queries
- Session persistence — history and settings preserved across sessions
- Multi-host failover —
-h host1,host2tries each in order, first success wins- SSH tunnel — connect through bastion hosts without manual port-forwarding
- Config profiles — per-project
.rpg.toml- Shell backtick substitution — dynamic prompts via
PROMPT1='[git branch --show-current] %/ # '- Status bar — connection info, transaction state, timing
- Cross-platform — single static binary: Linux, macOS, Windows (x86_64 + aarch64)
Journal du mercredi 03 décembre 2025 à 06:58
#JaiDécouvert usql (https://github.com/xo/usql) qui semble être une alternative à pgcli, écrit en Golang.
Je ne l'ai pas encore testé.