Allan McRae <[email protected]> wrote:
> On 04/08/13 02:26, Dave Reisner wrote:
>> +     if [[ $1 = ?(_[[:alpha:]])+([[:alnum:]_])?(+)=* ]]; then
>
> This matches "1=2" which then bails on the export.   Should it be:
>
> +(_[[:alpha:]])?([[:alnum:]_])?(+)=*
>

There must be a typo, I think it should be this:

[_[:alpha]]*([_[:alnum:]])?(+)

which also allows setting the special shell variable $_ but maybe it's fine.

Reply via email to