This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Gerry,
> This is really more pqact-related.  I'm trying the following, with <tab>
> for the whitespace:
> EXP     ^WMM5v370-TAM_(........)T(.*)DOMAIN3_Z.bin.gz
> FILE    -close
> data/TAMU/MM5/\1/WMM5v370-TAM_\1T\2DOMAIN3_Z.bin.gz
> 
> When I try to use 'regex' I get this error:
> 
> -bash-3.00$ regex -s
> WMM5v370-TAM_20070524T0000_20070526T1900_20070526T2000_00DOMAIN3_Z.bin.gz
> WMM5v370-TAM_(20[0-9][0-9][01][0-9][0123][0-9])T(.*)DOMAIN3_Z.bin.gz
> -bash: syntax error near unexpected token `('
> 
> Could you help with the application of a clue-by-4, please?
The characters in the string "()[]*" are metacharacters to the
shell, so if you want to use them, then you should quote the
argument that contains them:
regex -s 
WMM5v370-TAM_20070524T0000_20070526T1900_20070526T2000_00DOMAIN3_Z.bin.gz 
'WMM5v370-TAM_(20[0-9][0-9][01][0-9][0123][0-9])T(.*)DOMAIN3_Z.bin.gz'
Regards,
Steve Emmerson
Ticket Details
===================
Ticket ID: LGL-289314
Department: Support LDM
Priority: Normal
Status: Closed