Overview
Comment:Tidied up searches by putting everyrhing into lib.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: 9360136aa9ea0368ed87c39f40ca659c160943b616911e9f5fed15a8d846314d
User & Date: gawthrop@users.sourceforge.net on 1996-11-09 21:10:20.000
Other Links: branch diff | manifest | tags
Context
1996-11-09
21:16:19
*** empty log message *** check-in: abe44f2539 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
21:10:20
Tidied up searches by putting everyrhing into lib. check-in: 9360136aa9 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
21:09:43
Added lib path. check-in: d29e54ef95 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes
︙︙
10
11
12
13
14
15
16



17
18
19
20
21
22












23
24
25
26
27
28
29



30

31
32


33
34
35
36
37
38

39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64

65
66
67
68
69
70
71
72



73
# Copyright (c) P.J.Gawthrop 1996

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



## Revision 1.1  1996/11/01 12:34:54  peterg
## Initial revision
##
###############################################################

topic=$1












subtopic=$2
if [ "$subtopic" = "" ]; then
  subtopic='.'
fi;

if [ "$topic" = "comps" ]; then
  echo 'Components:'



  grep -h '\%SUMMARY' \

	$MTTPATH/comp/compound/*_lbl.txt  \
	$MTTPATH/comp/simple/*_cause.m \


	$MTTPATH/cr/r/*.cr|\
  sed 's/\%SUMMARY[ ]*/	/' |\
  grep $subtopic |\
  sed 's/:[ ]*/	/' |\
  sort


elif [ "$topic" = "reps" ]; then
  echo 'Representations:'
  grep  '#REPRESENTATION' $MTTPATH/mtt |\
  sed 's/#REPRESENTATION[	]*/	/' |\
  grep $subtopic |\
  sort

elif [ "$topic" = "crs" ]; then
  echo 'Constitutive relationships'
  grep -h '\%SUMMARY' \
	*.cr \
	$MTTPATH/cr/r/*.cr 2>/dev/null |\
  sed 's/\%SUMMARY[ ]*/	/' |\
  grep $subtopic |\
  sed 's/:[ ]*/	/' |\
  sort

else
  grep -h '\%SUMMARY' \
       $MTTPATH/comp/compound/$1_lbl.txt \
       $MTTPATH/comp/simple/$1_cause.m \
       $MTTPATH/cr/r/$1.cr \
       2>/dev/null |\
  sed 's/\%SUMMARY[ ]*//' |\
  sed 's/:[ ]*/	/'


  grep -h '\%DESCRIPTION' \
       $MTTPATH/comp/compound/$1_lbl.txt \
       $MTTPATH/comp/simple/$1_cause.m \
       $MTTPATH/cr/r/$1.cr \
	2>/dev/null |\
  sed 's/\%DESCRIPTION[	]*/	  /' |\
  sed 's/:[ ]*/	/'
fi;











>
>
>






>
>
>
>
>
>
>
>
>
>
>
>





|

>
>
>
|
>
|
|
>
>
|
<
|
|


>
|


|
|






|

|




<
<
<
|
<
<
<
|
>
|
<
<
<
|
|
<

>
>
>

10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54

55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77



78



79
80
81



82
83

84
85
86
87
88
# Copyright (c) P.J.Gawthrop 1996

###############################################################
## Version control history
###############################################################
## $Id$
## $Log$
# Revision 1.2  1996/11/02  10:22:54  peterg
# Now browses crs.
#
## Revision 1.1  1996/11/01 12:34:54  peterg
## Initial revision
##
###############################################################

topic=$1

if [ "$topic" = "" ]; then
    echo 'Usage: mtt help representations'
    echo '       mtt help components'
    echo '       mtt help CRs'    
    echo '       mtt help representations <match_string>'
    echo '       mtt help components <match_string>'
    echo '       mtt help examples  <match_string>'
    echo '       mtt help CRs <match_string>'
    echo '       mtt help <component_or_example_or_CR_name>'
fi

subtopic=$2
if [ "$subtopic" = "" ]; then
  subtopic='.'
fi;

if [ "$topic" = "components" ]; then
  echo 'Components:'
  find $MTTPATH/lib/comp \
    -name '*_lbl.txt' \
    -exec grep -i "%SUMMARY.*$subtopic.*" {} \; |\
  sed "s/%SUMMARY[	]*/  /" |\
  sort


elif [ "$topic" = "examples" ]; then
  echo 'Examples:'
  find $MTTPATH/lib/examples -name '*_lbl.txt' \

    -exec grep -i "%SUMMARY.*$subtopic.*" {} \; |\
  sed "s/%SUMMARY[	]*/  /" |\
  sort


elif [ "$topic" = "representations" ]; then
  echo 'Representations:'
  grep  '#REPRESENTATION' $MTTPATH/mtt |\
  sed 's/#REPRESENTATION[	]*/  /' |\
  grep -i $subtopic |\
  sort

elif [ "$topic" = "crs" ]; then
  echo 'Constitutive relationships'
  grep -h '\%SUMMARY' \
	*.cr \
	$MTTPATH/lib/cr/r/*.cr 2>/dev/null |\
  sed 's/\%SUMMARY[ ]*/	/' |\
  grep -i $subtopic |\
  sed 's/:[ ]*/	/' |\
  sort

else



  find $MTTPATH/lib \



   -name "$1_lbl.txt" \
   -exec grep  "%SUMMARY" {} \; \
   -exec grep  "%DESCRIPTION" {} \; |\



  sed "s/%SUMMARY[	]*//" |\
  sed "s/%DESCRIPTION[	]*/  /"

fi;





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