Overview
Comment:Handles #SUMMARY correctely
Refined count of subsystems within fig file (avoilds ports with same
name as system
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: a5e01661f1e7695c6ee9bde2165579c0db9b55e29936a97718ebc8c898acdaf9
User & Date: gawthrop@users.sourceforge.net on 2004-02-10 10:13:05
Other Links: branch diff | manifest | tags
Context
2004-02-10
10:22:10
Do proper arithmetic via let
Three levels of output
enumerate, not itemize
check-in: cbb1ac6c08 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
10:13:05
Handles #SUMMARY correctely
Refined count of subsystems within fig file (avoilds ports with same
name as system
check-in: a5e01661f1 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
09:51:07
Updated obsolete path name. check-in: d39722131b user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/bin/trans/sub_sh2tex from [6e3df96ad0] to [6934f464e2].

10
11
12
13
14
15
16



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

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



## Revision 1.1  2000/12/27 16:04:08  peterg
## Initial revision
##
## Revision 1.7  1998/02/04 10:59:37  peterg
## Tidied up.
##
# Revision 1.6  1997/09/08  19:42:37  peterg







>
>
>







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

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
## Revision 1.2  2004/02/10 09:51:07  gawthrop
## Updated obsolete path name.
##
## Revision 1.1  2000/12/27 16:04:08  peterg
## Initial revision
##
## Revision 1.7  1998/02/04 10:59:37  peterg
## Tidied up.
##
# Revision 1.6  1997/09/08  19:42:37  peterg
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111

# Write list item if not at the top level.
if [ -n "$2" ]; then
  #Set up some names
  filename=$2
  figfile=$3_abg.fig
  lblfile=$1_lbl.txt
  summary='%SUMMARY'

  #Get the system description, copying where necesary
  mtt -q -u compcopy $system $MTT_LIB/comp/compound
  # mtt -q -u $system lbl txt
  desc=`grep $summary $lblfile | sed "s/$summary//"`

  #Count the number of subsystems
  subs=`grep -c $system $figfile`

  if [ "$labels" = "yes" ]; then
    echo '  \item '$desc ' ('$subs') Section \Ref{sec:'$system'}' >> $filename
  else
    echo '  \item' $desc ' ('$subs')'   >> $filename
  fi
fi








|







|
|







91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114

# Write list item if not at the top level.
if [ -n "$2" ]; then
  #Set up some names
  filename=$2
  figfile=$3_abg.fig
  lblfile=$1_lbl.txt
  summary='[%|#]SUMMARY'

  #Get the system description, copying where necesary
  mtt -q -u compcopy $system $MTT_LIB/comp/compound
  # mtt -q -u $system lbl txt
  desc=`grep $summary $lblfile | sed "s/$summary//"`

  #Count the number of subsystems
  subs=`grep -c " $system" $figfile`
echo $system $figfile $lblfile $summary $desc $subs
  if [ "$labels" = "yes" ]; then
    echo '  \item '$desc ' ('$subs') Section \Ref{sec:'$system'}' >> $filename
  else
    echo '  \item' $desc ' ('$subs')'   >> $filename
  fi
fi

122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
EOF
	# Recursively generate the subsystems
        level1="$level+1"
	sh $system\_sub.sh "sub_sh2tex $arg " " $filename $system $level1" 
	cat <<EOF >> $filename
	    \end{$listtype}
EOF
else
    cat  <<EOF >> $filename
         No subsystems.
EOF
fi
fi















|
|
|
|










125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
EOF
	# Recursively generate the subsystems
        level1="$level+1"
	sh $system\_sub.sh "sub_sh2tex $arg " " $filename $system $level1" 
	cat <<EOF >> $filename
	    \end{$listtype}
EOF
#else
#    cat  <<EOF >> $filename
#         No subsystems.
#EOF
fi
fi









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