Revision 16,
1.2 KB
checked in by marcus, 14 years ago
(diff) |
r1 | svn | 2007-12-13 11:10:29 +0100 (Do, 13 Dez 2007) | 2 lines
Initial import
|
-
Property svn:executable set to
*
|
Line | |
---|
1 | #! /bin/csh |
---|
2 | # |
---|
3 | # file create_button_set.csh |
---|
4 | # ===================== |
---|
5 | # |
---|
6 | # version 1, 15-Nov-2003 |
---|
7 | # |
---|
8 | # Creates new button set with empty entries |
---|
9 | # K. Stammler, 15-Nov-2003 |
---|
10 | |
---|
11 | set xprog=$SH_ROOT/setup |
---|
12 | |
---|
13 | set maxset=`$xprog/noof_button_sets.csh` |
---|
14 | |
---|
15 | cd $SH_GLOBALS |
---|
16 | |
---|
17 | # check whether last button set is empty |
---|
18 | set lastname=`printf "STATLIST_%02d.STX" $maxset` |
---|
19 | set res=`grep -c '* ---' $lastname` |
---|
20 | if ($res >= 30) then |
---|
21 | echo "Last button set (number $maxset) is empty. Use this first." |
---|
22 | exit |
---|
23 | endif |
---|
24 | |
---|
25 | @ maxset = $maxset + 1 |
---|
26 | |
---|
27 | set newname=`printf "STATLIST_%02d.STX" $maxset` |
---|
28 | |
---|
29 | echo "" |
---|
30 | echo "creating button set number $maxset ($newname)" |
---|
31 | echo "" |
---|
32 | |
---|
33 | if (-e $newname) \rm $newname |
---|
34 | touch $newname |
---|
35 | echo "! file $newname" >> $newname |
---|
36 | echo "! ===============" >> $newname |
---|
37 | echo "!" >> $newname |
---|
38 | echo "! created using $0 at `date`" >> $newname |
---|
39 | echo "!" >> $newname |
---|
40 | echo "" >> $newname |
---|
41 | echo "set1: 0 14 HALF1" >> $newname |
---|
42 | echo "set2: 15 29 HALF2" >> $newname |
---|
43 | echo "" >> $newname |
---|
44 | set cnt=1 |
---|
45 | while ($cnt <= 30) |
---|
46 | echo "* ---" >> $newname |
---|
47 | @ cnt = $cnt + 1 |
---|
48 | end |
---|
Note: See
TracBrowser
for help on using the repository browser.