[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ! history expansion occurs within arithmetic substitutions
From: |
Dale R. Worley |
Subject: |
Re: ! history expansion occurs within arithmetic substitutions |
Date: |
Thu, 10 Aug 2023 14:21:47 -0400 |
Zachary Santer <zsanter@gmail.com> 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 that there's an explicit way to start
bash noninteractively, but running "cat | bash" seems to work. Of
course, it's noninteractive, so you get e.g. empty prompt strings!
My understanding is that "interactive" directly affects only two things,
the startup file(s) read and the initial values of various shell
options. You can fix the startup files with explicit options on
invocation, and you can fix the shell options that matter to you with
commands.
Dale
- ! history expansion occurs within arithmetic substitutions, (continued)
- ! history expansion occurs within arithmetic substitutions, Zachary Santer, 2023/08/08
- Re: ! history expansion occurs within arithmetic substitutions, Emanuele Torre, 2023/08/08
- Re: ! history expansion occurs within arithmetic substitutions, Martin D Kealey, 2023/08/08
- Re: ! history expansion occurs within arithmetic substitutions, Dale R. Worley, 2023/08/08
- Re: ! history expansion occurs within arithmetic substitutions, Andreas Schwab, 2023/08/08
- Re: ! history expansion occurs within arithmetic substitutions, Dale R. Worley, 2023/08/11
- Re: ! history expansion occurs within arithmetic substitutions, Martin D Kealey, 2023/08/11
- Re: ! history expansion occurs within arithmetic substitutions, Chet Ramey, 2023/08/14
- Re: ! history expansion occurs within arithmetic substitutions, Martin D Kealey, 2023/08/15
- Re: ! history expansion occurs within arithmetic substitutions, Zachary Santer, 2023/08/08
- Re: ! history expansion occurs within arithmetic substitutions,
Dale R. Worley <=
- Re: ! history expansion occurs within arithmetic substitutions, Lawrence Velázquez, 2023/08/10
Re: !; is interpreted as an history expansion that can never match anything, Dale R. Worley, 2023/08/08
Re: !; is interpreted as an history expansion that can never match anything, Chet Ramey, 2023/08/08