$ X=`seq -s "|" 1 12`
$ echo ${X}
1|2|3|4|5|6|7|8|9|10|11|12
wgrib2のmatchでワイルドカード的なことがやりたかったため。
$ X=":PRATE:surface:(`seq -s "|" 1 12`) hour fcst:"
$ echo ${X}
:PRATE:surface:(1|2|3|4|5|6|7|8|9|10|11|12) hour fcst:
$ wgrib2 ~/Workspace/gfs-shell/data/atmos/gfs.t00z.pgrb2.0p25.f001 -match "${X}"
3:1392910:d=2021061600:PRATE:surface:1 hour fcst:
$ wgrib2 ~/Workspace/gfs-shell/data/atmos/gfs.t00z.pgrb2.0p25.f006 -match "${X}"
3:1404951:d=2021061600:PRATE:surface:6 hour fcst:
$ wgrib2 ~/Workspace/gfs-shell/data/atmos/gfs.t00z.pgrb2.0p25.f012 -match "${X}"
3:1407884:d=2021061600:PRATE:surface:12 hour fcst:
$ wgrib2 ~/Workspace/gfs-shell/data/atmos/gfs.t00z.pgrb2.0p25.f018 -match "${X}"
↧