janus
janus copied to clipboard
Janus breaks \e in psql
Something in Janus is causing this issue:
I'm trying to edit a query using \e in postgres, but upon savequitting :wq nothing happens. Running \p, which shows what the editor saved, just comes up with a blank line, or whatever I ran most recently in the cli. It seems likethe editor is not persisting whatsoever.
I've confirmed that if I remove the .vimrc installed by Janus, then the issue goes away.
Things get even weirder when I tried to dig deeper:
If I do \e then append to the file outside of vim, the issue still occurs.
This is probably best demonstrated by example, see here.
I've suggested a workaround on the Stack Overflow question:
In the interim add the following to your ~/.profile as a workaround:
export PSQL_EDITOR="vim -u NONE"
See:
vim -uswitch.PSQL_EDITORenv var.