Created
August 11, 2016 18:50
-
-
Save gerrard00/83a724b56b3126f641e6ee797505fabf to your computer and use it in GitHub Desktop.
Show postgresql query results in terminal with a nicer format than psql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pgsql_execfile () { | |
clear | |
echo "\n" | |
tmpfile="$(mktemp).html" | |
nodemon --exec "psql -U postgres -h localhost -p 5433 -d $1 -f $2 --html -- > $tmpfile && w3m -dump $tmpfile && echo " $2 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment