I'm trying to add a new terminal Postgres shell (psql) to the Windows Terminal. I want to add it to the profiles list in the settings.
This is the windows terminal.
In the settings file, we can add a list of profiles. In that list, I have Windows PowerShell, Command prompt, and Azure Cloud Shell.
How do I add psql shell on that list?
{
"guid": "{some guid}",
"hidden": false,
"name": "SQL Shell (psql)",
"source": ?
}
I looked up various articles on this, but none of them has a working solution.
Can anyone help me with this?
I somehow figured it out! The profile settings are:
{
"commandline" : "\"%PROGRAMFILES%\\PostgreSQL\\12\\scripts\\runpsql.bat\" -i -l",
"hidden": false,
"name": "PostgreSQL",
"icon" : "PostgreSQL.png*",
"background" : "#1b364d",
"cursorShape" : "vintage"
}
I also searched for the guid for some time, and then I remembered that I had added Git Bash to Windows Terminal. So I copied that executable, replaced the value with psql batch file address, and voilà!
*PostgreSQL.png
you can get the guid down below if you want, i got it from here: https://www.postgresql.org/docs/8.3/datatype-uuid.html
"guid": "{a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11}",
"name" : "SQL psql",
"commandline": "%PROGRAMFILES%/PostgreSQL/13/scripts/runpsql.bat -i -l",
"hidden": false,
"icon": "%SystemDrive%/PROGRA~1/PostgreSQL/13/scripts/images/pg-psql.ico",
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With