Index: mttroot/mtt/bin/mtt ================================================================== --- mttroot/mtt/bin/mtt +++ mttroot/mtt/bin/mtt @@ -12,10 +12,14 @@ ############################################################### ## Version control history ############################################################### ## $Header$ ## $Log$ +# Revision 1.105 1997/12/11 09:04:47 peterg +# Reduced default rep.txt file to just abg.txt -- this is to document +# components which may not be causally complete +# # Revision 1.104 1997/12/07 21:05:10 peterg # Removed a debbugging echo # ## Revision 1.103 1997/12/07 20:10:36 peterg ## Fixed bugs with reprots and distinguish between book, article and @@ -403,10 +407,12 @@ -s ) mtt_switches="$mtt_switches $1"; switches=1 ;; -d ) directory=$2; cd $directory; shift ;; + -D ) + debug=debug ;; -l ) mtt_switches="$mtt_switches $1"; level=$2; shift ;; *) echo "$1 is an invalid argument - ignoring" ;; @@ -420,10 +426,16 @@ echo 'MTT (Model Transformation Tools) version 2.5++ ($Date$)' echo 'This is free software with ABSOLUTELY NO WARRANTY.' echo 'Type `mtt warranty'\' 'for details.' echo fi + +# Print current directory if in -d mode +if [ -n "$directory" ]; then + echo Using directory $directory + echo +fi #Check the principle paths mtt_check_vars $print # Exit if just printing paths @@ -449,10 +461,11 @@ echo ' -p print environment variables' echo ' -c c-code generation' echo ' -o ode and dae are the same' echo ' -s use switch (ISW and CSW) components' echo ' -d use directory ' + echo ' -D debug -- leave log files etc' exit fi fi @@ -1450,7 +1463,14 @@ # Tidy up. # echo Removing log files and other garbage rm -f *_unique_raw_list *_raw_list rm -f mtt_error.txt mtt_info.txt a.out - rm -f *.log mtt_info.txt warning.txt + rm -f mtt_info.txt warning.txt # rm -f *_*.idx *_*.ind *_*.ilg *_*.lof *_*.toc + +# Remove logs if not debugging +if [ "$debug" != "debug" ]; then + rm -f *.log +else + echo Debugging - log files retained +fi