Skip to content
This repository was archived by the owner on Oct 13, 2025. It is now read-only.

pka/nupsql

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

psql plugin for Nu Shell

Execute PostgreSQL commands from Nu Shell.

Usage

> help psql
Execute PostgreSQL query.

Usage:
  > psql <conn> <query> 

Usage examples:

> psql postgresql://postgres@127.0.0.1/postgres "SELECT * FROM pg_stat_activity WHERE state IS NOT NULL" | pivot
━━━━┯━━━━━━━━━━━━━━━━━━┯━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
 #  │ Column0          │ Column1 
────┼──────────────────┼────────────────────────────────
  0 │ datid            │  
  1 │ datname          │  
  2 │ pid              │                           3299 
  3 │ usesysid         │  
  4 │ usename          │  
  5 │ application_name │  
  6 │ client_addr      │  
  7 │ client_hostname  │  
  8 │ client_port      │                          36932 
  9 │ backend_start    │  
 10 │ xact_start       │  
 11 │ query_start      │  
 12 │ state_change     │  
 13 │ waiting          │  
 14 │ state            │ active 
 15 │ query            │ SELECT * FROM pg_stat_activity 
━━━━┷━━━━━━━━━━━━━━━━━━┷━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Installation

cargo build
cargo install --path .

About

psql plugin for Nu Shell

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages