psql не работает? Вот решение! / psql not working? Here’s the fix!(PostgreSQL)

Опубликовано: 17 Июнь 2026
на канале: Joojos
47
1

После установки PostgreSQL у меня psql запускался неправильно: вместо psql открывался обычный терминал. Это решение — единственное, которое мне удалось найти. В этом видео показываю, как я это починил — мы пишем небольшую программку/обёртку, которая запускает psql корректно, чтобы всё работало как должно.

After installing PostgreSQL, my psql was launching incorrectly: instead of psql, it would just open a regular Terminal window. This is the only solution I managed to find. In this video, I show how I fixed it — we create a small helper wrapper app/script that launches psql correctly so everything works as expected.

Код из видео ниже / The code from the video is below

on run {input, parameters}
set cmd to "bash " & quoted form of "/Library/PostgreSQL/18/scripts/runpsql.sh"
tell application "Terminal"
activate
if (count of windows) is 0 then
do script cmd
else
do script cmd in selected tab of front window
end if
end tell
return input
end run