[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Inconsistency between fc and C-x C-e

From: Luciano
Subject: Inconsistency between fc and C-x C-e
Date: Wed, 8 Jun 2022 18:06:51 -0300

I had the terrible idea to set my EDITOR variable to something too
complex. I had to pass some options with whitespace to vim, so i decided
to use `eval`. I managed to get something working, but the way the
EDITOR variable is interpreted isn't consistent 
to provide an example, if one sets EDITOR in .bashrc to: 
EDITOR="eval vim --cmd \" set statusline=HI-FROM-\\\$EDITOR laststatus=2  \" -- 
then doing 'fc' works fine, (I get the "HI-FROM-$EDITOR" message on the
status line"), but C-x C-e seems to wipe out the ' \" ' arguments altogether,
leaving eval with only loose words after '--cmd'.
C-x C-e seems to have an extra pass with character escaping, doubling
every \ character makes C-x C-e work as intended, but now fc doesn't
work anymore!
By the way, fc seems to be the one that works as intended, because
programs such as pass interpret the $EDITOR variable the same way as fc
This is clearly not a very important bug, I know! 
Greetings. Luciano

reply via email to

[Prev in Thread] Current Thread [Next in Thread]