Last change
on this file since 3530 was
11,
checked in by aslmd, 14 years ago
|
spiga@svn-planeto:ajoute le modele meso-echelle martien
|
-
Property svn:executable set to
*
|
File size:
1.3 KB
|
Line | |
---|
1 | #!/bin/csh |
---|
2 | |
---|
3 | set alpha = ( A B C D E F G H I J K L M N O P Q R S T U V W X Y Z ) |
---|
4 | set i1 = 1 |
---|
5 | set i2 = 1 |
---|
6 | set i3 = 1 |
---|
7 | |
---|
8 | if ( ( ${#argv} == 1 ) || ( ( ${#argv} == 2 ) && ( ${2} == "." ) ) ) then |
---|
9 | |
---|
10 | rm -f GRIBFILE.??? >& /dev/null |
---|
11 | |
---|
12 | foreach f ( ${1}* ) |
---|
13 | |
---|
14 | ln -sf ${f} GRIBFILE.$alpha[$i3]$alpha[$i2]$alpha[$i1] |
---|
15 | @ i1 ++ |
---|
16 | |
---|
17 | if ( $i1 > 26 ) then |
---|
18 | set i1 = 1 |
---|
19 | @ i2 ++ |
---|
20 | if ( $i2 > 26 ) then |
---|
21 | set i2 = 1 |
---|
22 | @ i3 ++ |
---|
23 | if ( $i3 > 26 ) then |
---|
24 | echo "RAN OUT OF GRIB FILE SUFFIXES!" |
---|
25 | endif |
---|
26 | endif |
---|
27 | endif |
---|
28 | |
---|
29 | end |
---|
30 | else if ( ${#argv} > 1 ) then |
---|
31 | |
---|
32 | rm -f GRIBFILE.??? >& /dev/null |
---|
33 | |
---|
34 | foreach f ( $* ) |
---|
35 | |
---|
36 | if ( $f != "." ) then |
---|
37 | ln -sf ${f} GRIBFILE.$alpha[$i3]$alpha[$i2]$alpha[$i1] |
---|
38 | @ i1 ++ |
---|
39 | |
---|
40 | if ( $i1 > 26 ) then |
---|
41 | set i1 = 1 |
---|
42 | @ i2 ++ |
---|
43 | if ( $i2 > 26 ) then |
---|
44 | set i2 = 1 |
---|
45 | @ i3 ++ |
---|
46 | if ( $i3 > 26 ) then |
---|
47 | echo "RAN OUT OF GRIB FILE SUFFIXES!" |
---|
48 | endif |
---|
49 | endif |
---|
50 | endif |
---|
51 | endif |
---|
52 | |
---|
53 | end |
---|
54 | else if ( ${#argv} == 0 ) then |
---|
55 | echo " " |
---|
56 | echo " " |
---|
57 | echo " Please provide some GRIB data to link" |
---|
58 | echo " usage: $0 path_to_grib_data/grib_data_root" |
---|
59 | echo " " |
---|
60 | echo " " |
---|
61 | endif |
---|
62 | |
---|
Note: See
TracBrowser
for help on using the repository browser.