1 # .Sanitize for devo/config
3 # Each directory to survive its way into a release will need a file
4 # like this one called "./.Sanitize". All keyword lines must exist,
5 # and must exist in the order specified by this file. Each directory
6 # in the tree will be processed, top down, in the following order.
8 # Hash started lines like this one are comments and will be deleted
9 # before anything else is done. Blank lines will also be squashed
12 # The lines between the "Do-first:" line and the "Things-to-keep:"
13 # line are executed as a /bin/sh shell script before anything else is
14 # done in this directory.
18 if ( echo $* | grep keep\-r5900 > /dev/null ) ; then
19 keep_these_too="${keep_these_too} mt-r5900"
21 lose_these_too="${lose_these_too} mt-r5900"
24 if ( echo $* | grep lose\-mswin > /dev/null ) ; then
25 lose_these_too="${lose_these_too} mh-windows"
27 keep_these_too="${keep_these_too} mh-windows"
30 if ( echo $* | grep keep\-sky > /dev/null ) ; then
31 keep_these_too="${keep_these_too} mt-sky"
33 lose_these_too="${lose_these_too} mt-sky"
36 # All files listed between the "Things-to-keep:" line and the
37 # "Do-last:" line will be kept. All other files will be removed.
38 # Directories listed in this section will have their own Sanitize
39 # called. Directories not listed will be removed in their entirety
98 # The lines between the "Do-last:" line and the end of the file
99 # are executed as a /bin/sh shell script after everything else is
104 r5900_files="ChangeLog"
105 if ( echo $* | grep keep\-r5900 > /dev/null ) ; then
106 for i in $r5900_files ; do
107 if test ! -d $i && (grep sanitize-r5900 $i > /dev/null) ; then
108 if [ -n "${verbose}" ] ; then
109 echo Keeping r5900 stuff in $i
114 for i in $r5900_files ; do
115 if test ! -d $i && (grep sanitize-r5900 $i > /dev/null) ; then
116 if [ -n "${verbose}" ] ; then
117 echo Removing traces of \"r5900\" from $i...
120 sed '/start\-sanitize\-r5900/,/end-\sanitize\-r5900/d' < $i > new
121 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
122 if [ -n "${verbose}" ] ; then
123 echo Caching $i in .Recover...
132 sky_files="ChangeLog"
133 if ( echo $* | grep keep\-sky > /dev/null ) ; then
134 for i in $sky_files ; do
135 if test ! -d $i && (grep sanitize-sky $i > /dev/null) ; then
136 if [ -n "${verbose}" ] ; then
137 echo Keeping sky stuff in $i
142 for i in $sky_files ; do
143 if test ! -d $i && (grep sanitize-sky $i > /dev/null) ; then
144 if [ -n "${verbose}" ] ; then
145 echo Removing traces of \"sky\" from $i...
148 sed '/start\-sanitize\-sky/,/end-\sanitize\-sky/d' < $i > new
149 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
150 if [ -n "${verbose}" ] ; then
151 echo Caching $i in .Recover...
160 cygnus_files="mh-go32"
161 if ( echo $* | grep keep\-cygnus > /dev/null ) ; then
162 for i in $cygnus_files ; do
163 if test ! -d $i && (grep sanitize-cygnus $i > /dev/null) ; then
164 if [ -n "${verbose}" ] ; then
165 echo Keeping cygnus stuff in $i
170 for i in $cygnus_files ; do
171 if test ! -d $i && (grep sanitize-cygnus $i > /dev/null) ; then
172 if [ -n "${verbose}" ] ; then
173 echo Removing traces of \"cygnus\" from $i...
176 sed '/start\-sanitize\-cygnus/,/end-\sanitize\-cygnus/d' < $i > new
177 if [ -n "${safe}" -a ! -f .Recover/$i ] ; then
178 if [ -n "${verbose}" ] ; then
179 echo Caching $i in .Recover...