On Sat, Aug 21, 2021, at 6:02 PM, Hunter Wittenborn wrote:
> In my head, something like this (where 'value' is equal to 'y'):
>
> `declare "${value}"="x"`
>
> becomes this (which it appears to do so):
>
> `declare "y"="x"`
Almost. The argument parses without issue ('=' has no special
meaning
i wrote, i write again
declare "var=value"
not
declare "var"="value"
On Sun, Aug 22, 2021, 00:02 Hunter Wittenborn
wrote:
> > As an end user I would expect the unquoted `('
>
> > operator to cause a syntax error, just as it does in `echo ('.
>
>
>
> Well I'm expecting '(' to be part of the
> As an end user I would expect the unquoted `('
> operator to cause a syntax error, just as it does in `echo ('.
Well I'm expecting '(' to be part of the shell's syntax (when unquoted; so
likewise not cause a syntax error), but when looking at things like the left
side of a variable
> On Fri, Aug 20, 2021 at 10:30 PM hancooper via Bug reports for the GNU
> Bourne Again SHell bug-bash@gnu.org wrote:
>
> I am using EPOCHREALTIME and then computing the corresponding human
> readable form, that can handle
> changes in locale
> now=$EPOCHREALTIME
> printf -v second '%(%S)T.%s'
Date:Sat, 21 Aug 2021 07:28:23 +0200
From:Emanuele Torre
Message-ID:
| I have also read that gettimeofday() is considered obsolete and is
| deprecated by POSIX.
It is being removed as a required interface, but it still exists
everywhere (and will for a very
‐‐‐ Original Message ‐‐‐
On Saturday, August 21, 2021 11:25 AM, Ilkka Virta wrote:
> What do you get with [![:digit:]] then? It seems to work the same with both
> ! and ^ here:
>
> $ now=$EPOCHREALTIME
> $ echo "${now%[^[:digit:]]}" "${now#[^[:digit:]]}"
> 1629544775 183030
> $ echo
Configuration Information [Automatically generated, do not change]:
Machine: x86_64
OS: linux-gnu
Compiler: gcc
Compilation CFLAGS: -march=x86-64 -mtune=generic -O2 -pipe -fno-plt
-DDEFAULT_PATH_VALUE='/usr/local/
uname output: Linux t420 5.10.54-1-lts #1 SMP Wed, 28 Jul 2021
15:05:20 + x86_64
What do you get with [![:digit:]] then? It seems to work the same with both
! and ^ here:
$ now=$EPOCHREALTIME
$ echo "${now%[^[:digit:]]*}" "${now#*[^[:digit:]]}"
1629544775 183030
$ echo "${now%[![:digit:]]*}" "${now#*[![:digit:]]}"
1629544775 183030
On Fri, Aug 20, 2021 at 10:30 PM