Changeset 2412
- Timestamp:
- Dec 17, 2015, 12:11:35 PM (9 years ago)
- Location:
- LMDZ5/trunk/tools
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ5/trunk/tools/compare_real.py
r2082 r2412 1 #!/usr/bin/env python 1 """This script should be called by "diffdef.sh". It operates on 2 different lines with common variables. It requires version 2.7 or 3 higher of Python (it also works with Python 3). 2 4 3 # Author: Lionel GUEZ 4 5 # This script should be called by "diffdef.sh". It operates on 6 # different lines with common variables. It requires version 2.7 or 7 # higher of Python (it also works with Python 3). 5 Author: Lionel GUEZ""" 8 6 9 7 import sys, os.path -
LMDZ5/trunk/tools/diffdef.sh
r2101 r2412 3 3 4 4 # This script compares files "*.def" other than "traceur.def" and 5 # "out.def" in two directories. The script uses GNU versions of the 6 # utilities cut, sort and uniq. 5 # "out.def" in two directories. 6 7 # This script uses GNU versions of the utilities cut, sort and uniq, 8 # and calls a Python script. 7 9 8 10 # See guide: … … 18 20 19 21 ##set -x 22 23 type python3 >/dev/null 2>&1 24 if (($? == 0)) 25 then 26 my_python=python3 27 else 28 my_python=python 29 fi 30 20 31 set -e 21 32 … … 51 62 cat plouf_$$ 52 63 rm plouf_$$ 64 rm all.def 53 65 exit 1 54 66 fi … … 81 93 done 82 94 83 $ script_dir/compare_real.py $*95 $my_python $script_dir/compare_real.py $* 84 96 sort common_lines --output=common_lines # was modified by the Python script 85 97 echo "Created files \"./common_lines\" and \"./uniq_val\"."
Note: See TracChangeset
for help on using the changeset viewer.