Re: !; is interpreted as an history expansion that can never match anything

2023-08-10 Thread Chet Ramey
On 8/8/23 3:30 PM, Dale R. Worley wrote: Emanuele Torre writes: ! followed by a ; or another terminator is interpreted as an history expansion with no pattern that can never match anything. $ !; echo hi bash: !: event not found $ !&& echo hi bash: !: event not found IMHO it is m

Re: ! history expansion occurs within arithmetic substitutions

2023-08-10 Thread Dale R. Worley
Zachary Santer writes: > When messing around in interactive mode to test things I may want to do in > a script, it's nice if it actually behaves the same. There are probably > some other set and possibly shopt things I should have somewhere if that's > what I want. I checked, and it doesn't seem

Re: ! history expansion occurs within arithmetic substitutions

2023-08-10 Thread Lawrence Velázquez
On Thu, Aug 10, 2023, at 2:21 PM, Dale R. Worley wrote: > My understanding is that "interactive" directly affects only two things, > the startup file(s) read and the initial values of various shell > options. There are more differences than that. https://www.gnu.org/software/bash/manual/html_node