Overview
Comment:Stopped initialisation of mttopen from over-writing logic.txt contents.
- comment removed from "sort" input (which put it last) because
initialisation is inserted in place of the comment by switch_txt2m.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: d3736ff8dc013a08eedba764ab9e9c2ddda8a99c6bb82b4b019a1906f5c55863
User & Date: geraint@users.sourceforge.net on 2001-08-02 03:01:08
Other Links: branch diff | manifest | tags
Context
2001-08-02
03:24:48
Replaced mtt_version.sh with mtt_banner.sh - I think this was the intent. check-in: c57496c6ff user: geraint@users.sourceforge.net tags: origin/master, trunk
03:01:08
Stopped initialisation of mttopen from over-writing logic.txt contents.
- comment removed from "sort" input (which put it last) because
initialisation is inserted in place of the comment by switch_txt2m.
check-in: d3736ff8dc user: geraint@users.sourceforge.net tags: origin/master, trunk
2001-08-01
22:16:01
Return input vector unchanged so that dassl can do the hard stuff. check-in: 864c3c4711 user: geraint@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/bin/trans/struc2switch_txt from [6af1bcdda6] to [178de24ab3].

11
12
13
14
15
16
17



18
19
20
21
22
23
24
# Copyright (c) P.J.Gawthrop, 1997.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$



## Revision 1.4  1998/07/26 10:28:30  peterg
## Added a header line to avoid empty file and to trigger
## switch_txt2m to write initial stuff.
##
## Revision 1.3  1998/07/25 18:50:53  peterg
## Lower case names
##







>
>
>







11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# Copyright (c) P.J.Gawthrop, 1997.

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.5  2000/10/17 09:20:00  peterg
## *** empty log message ***
##
## Revision 1.4  1998/07/26 10:28:30  peterg
## Added a header line to avoid empty file and to trigger
## switch_txt2m to write initial stuff.
##
## Revision 1.3  1998/07/25 18:50:53  peterg
## Lower case names
##
32
33
34
35
36
37
38
39
40
41

42
43


44
45
46
47
48
49
50




echo Creating  $1_switch.txt

rm -f $1_switch.txt
# This is the main transformation using awk
awk 'BEGIN{
printf("# These are the switches deduced from ISW and CSW components\n");

}
{ 


   if ($1=="state") {i++; if ($3=="MTT_SWITCH")  print tolower($4) "\t" i};
}
END{
}
' < $1_struc.txt| sort >> $1_switch.txt

strip_comments < $1_switch.txt | wc -l | awk '{print $1 " switches found"}'







<
<
|
>
|
<
>
>







35
36
37
38
39
40
41


42
43
44

45
46
47
48
49
50
51
52
53




echo Creating  $1_switch.txt

rm -f $1_switch.txt


echo "# These are the switches deduced from ISW and CSW components"\
 > $1_switch.txt


# This is the main transformation using awk
awk '{ 
   if ($1=="state") {i++; if ($3=="MTT_SWITCH")  print tolower($4) "\t" i};
}
END{
}
' < $1_struc.txt| sort >> $1_switch.txt

strip_comments < $1_switch.txt | wc -l | awk '{print $1 " switches found"}'


MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]