Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > gnu.bash.bug > #14464
| From | Chet Ramey <chet.ramey@case.edu> |
|---|---|
| Newsgroups | gnu.bash.bug |
| Subject | Re: History expansion in multiline string, within single quote |
| Date | 2018-08-09 10:32 -0400 |
| Message-ID | <mailman.4905.1533825191.1292.bug-bash@gnu.org> (permalink) |
| References | <2025014165.1152724.1533800844049.JavaMail.zimbra@laposte.net> |
On 8/9/18 3:47 AM, schplurtz@laposte.net wrote: > Bash Version: 4.4 > Patch Level: 12 > Release Status: release > > Description: > Bug happens in an interactive shell. > > this works as expected, no history expansion : > echo "foo"'!bar'"qux" > > but this fails, bash tries to hist-expand !bar', which it should not. > echo "foo > "'!bar'"qux" > > -bash: !bar': event not found > > I just compiled bash 4.4.18 and tested, the bug is there too. Since the history library is explicitly line-oriented, and independent of the shell, there hasn't been a clean way to inform it about any quoting state the current line should inherit. I added an experimental new state variable that will appear in readline-8.0-beta that should allow applications to communicate this state to the history library. We'll see how it works. Chet -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
Back to gnu.bash.bug | Previous | Next | Find similar | Unroll thread
Re: History expansion in multiline string, within single quote Chet Ramey <chet.ramey@case.edu> - 2018-08-09 10:32 -0400
csiph-web