From 65574036cd6833e4bbc52473202f898cf21c29b0 Mon Sep 17 00:00:00 2001 From: Thomas Applencourt Date: Wed, 13 May 2015 15:42:53 +0200 Subject: [PATCH] Move some file to be logic --- scripts/ezfio_interface/ei_handler.py | 2 +- scripts/{ => install}/fetch_from_web.py | 0 scripts/install/install_curl.sh | 2 +- scripts/install/install_docopt.sh | 4 ++-- scripts/install/install_emsl.sh | 2 +- scripts/install/install_ezfio.sh | 2 +- scripts/install/install_irpf90.sh | 2 +- scripts/install/install_m4.sh | 2 +- scripts/install/install_ocaml.sh | 2 +- scripts/install/install_resultsFile.sh | 2 +- scripts/install/install_zlib.sh | 2 +- scripts/module/build_modules.sh | 10 +++++----- scripts/{ => module}/check_module.sh | 0 scripts/{ => module}/check_src.sh | 0 scripts/module/module_handler.py | 2 +- scripts/{ => module}/update_README.py | 0 scripts/{qp_utils.py => utility/cache.py} | 0 scripts/{module => utility}/pydot.py | 0 18 files changed, 17 insertions(+), 17 deletions(-) rename scripts/{ => install}/fetch_from_web.py (100%) rename scripts/{ => module}/check_module.sh (100%) rename scripts/{ => module}/check_src.sh (100%) rename scripts/{ => module}/update_README.py (100%) rename scripts/{qp_utils.py => utility/cache.py} (100%) rename scripts/{module => utility}/pydot.py (100%) diff --git a/scripts/ezfio_interface/ei_handler.py b/scripts/ezfio_interface/ei_handler.py index aa44da33..6e832aa8 100755 --- a/scripts/ezfio_interface/ei_handler.py +++ b/scripts/ezfio_interface/ei_handler.py @@ -63,7 +63,7 @@ from collections import defaultdict from collections import namedtuple -from qp_utils import cache +from cache import cache Type = namedtuple('Type', 'fancy ocaml fortran') diff --git a/scripts/fetch_from_web.py b/scripts/install/fetch_from_web.py similarity index 100% rename from scripts/fetch_from_web.py rename to scripts/install/fetch_from_web.py diff --git a/scripts/install/install_curl.sh b/scripts/install/install_curl.sh index b2e47481..5f32e384 100755 --- a/scripts/install/install_curl.sh +++ b/scripts/install/install_curl.sh @@ -22,7 +22,7 @@ then fi rm -f -- ${QPACKAGE_ROOT}/bin/curl -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${CURL_URL} CURL.tar.bz2 +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${CURL_URL} CURL.tar.bz2 tar -jxf CURL.tar.bz2 && rm CURL.tar.bz2 ||exit 1 cd ${CURL} || exit 1 mv curl.ermine ${QPACKAGE_ROOT}/bin/curl diff --git a/scripts/install/install_docopt.sh b/scripts/install/install_docopt.sh index 6f799c47..65a01f0f 100755 --- a/scripts/install/install_docopt.sh +++ b/scripts/install/install_docopt.sh @@ -16,6 +16,6 @@ fi cd ${QPACKAGE_ROOT} rm -f -- scripts/${DOCOPT}{,c} -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${DOCOPT_URL} ${DOCOPT} +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${DOCOPT_URL} ${DOCOPT} -mv ${DOCOPT} scripts/${DOCOPT} \ No newline at end of file +mv ${DOCOPT} scripts/utility/${DOCOPT} \ No newline at end of file diff --git a/scripts/install/install_emsl.sh b/scripts/install/install_emsl.sh index b01afb6e..b0bbc820 100755 --- a/scripts/install/install_emsl.sh +++ b/scripts/install/install_emsl.sh @@ -15,7 +15,7 @@ fi cd ${QPACKAGE_ROOT} -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/${BASE}.tar.gz +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/${BASE}.tar.gz tar -zxf ${BASE}.tar.gz && rm ${BASE}.tar.gz ||exit 1 rm -rf EMSL_Basis mv ${BASE}-master EMSL_Basis diff --git a/scripts/install/install_ezfio.sh b/scripts/install/install_ezfio.sh index c0033ca8..7e9a39e2 100755 --- a/scripts/install/install_ezfio.sh +++ b/scripts/install/install_ezfio.sh @@ -16,7 +16,7 @@ fi cd ${QPACKAGE_ROOT} rm -rf -- EZFIO -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/${BASE}.tar.gz +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/${BASE}.tar.gz tar -zxf ${BASE}.tar.gz && rm ${BASE}.tar.gz ||exit 1 mv EZFIO-master EZFIO diff --git a/scripts/install/install_irpf90.sh b/scripts/install/install_irpf90.sh index d93340d2..d7043882 100755 --- a/scripts/install/install_irpf90.sh +++ b/scripts/install/install_irpf90.sh @@ -17,7 +17,7 @@ fi cd ${QPACKAGE_ROOT} -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/${BASE}.tar.gz +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/${BASE}.tar.gz tar -zxf ${BASE}.tar.gz && rm ${BASE}.tar.gz ||exit 1 mv ${BASE}-master irpf90 make -C irpf90 | tee install_irpf90.log diff --git a/scripts/install/install_m4.sh b/scripts/install/install_m4.sh index 6f012d04..2ccf00a1 100755 --- a/scripts/install/install_m4.sh +++ b/scripts/install/install_m4.sh @@ -19,7 +19,7 @@ cd ${QPACKAGE_ROOT} if [[ -z ${M4} ]] then rm -f -- bin/m4 - ${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${M4_URL} M4.tar.gz + ${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${M4_URL} M4.tar.gz tar -zxf M4.tar.gz && rm M4.tar.gz ||exit 1 cd m4* || exit 1 ./configure && make || exit 1 diff --git a/scripts/install/install_ocaml.sh b/scripts/install/install_ocaml.sh index 1cefba6c..fe02e9df 100755 --- a/scripts/install/install_ocaml.sh +++ b/scripts/install/install_ocaml.sh @@ -45,7 +45,7 @@ then done fi fi -${QPACKAGE_ROOT}/scripts/fetch_from_web.py \ +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py \ "https://raw.github.com/ocaml/opam/master/shell/opam_installer.sh" opam_installer.sh chmod +x opam_installer.sh echo N | ./opam_installer.sh ${QPACKAGE_ROOT}/bin diff --git a/scripts/install/install_resultsFile.sh b/scripts/install/install_resultsFile.sh index 6f279ffa..dc5c5d11 100755 --- a/scripts/install/install_resultsFile.sh +++ b/scripts/install/install_resultsFile.sh @@ -17,7 +17,7 @@ cd ${QPACKAGE_ROOT} rm -rf resultsFile-master -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/resultsFile.tar.gz +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${URL} ${QPACKAGE_ROOT}/resultsFile.tar.gz tar -zxf resultsFile.tar.gz && rm resultsFile.tar.gz ||exit 1 mv resultsFile-master resultsFile diff --git a/scripts/install/install_zlib.sh b/scripts/install/install_zlib.sh index 9250edf1..30f0055b 100755 --- a/scripts/install/install_zlib.sh +++ b/scripts/install/install_zlib.sh @@ -28,7 +28,7 @@ then fi rm /tmp/main.c -${QPACKAGE_ROOT}/scripts/fetch_from_web.py ${ZLIB_URL} ZLIB.tar.gz +${QPACKAGE_ROOT}/scripts/install/fetch_from_web.py ${ZLIB_URL} ZLIB.tar.gz tar -zxf ZLIB.tar.gz && rm ZLIB.tar.gz ||exit 1 cd ${ZLIB} || exit 1 ./configure && make diff --git a/scripts/module/build_modules.sh b/scripts/module/build_modules.sh index 4280e3b9..03fa5d7a 100755 --- a/scripts/module/build_modules.sh +++ b/scripts/module/build_modules.sh @@ -3,7 +3,7 @@ # This script should run from the directory $QPACKAGE_ROOT/src # Check is we are in `QPROOT_SRC` and all the dependancy are corect -${QPACKAGE_ROOT}/scripts/check_src.sh +${QPACKAGE_ROOT}/scripts/module/check_src.sh NPROC=$(cat /proc/cpuinfo | grep MHz | wc -l) @@ -19,14 +19,11 @@ do echo ${MODULE} # Update Makefile.depend - ${QPACKAGE_ROOT}/scripts/check_module.sh + ${QPACKAGE_ROOT}/scripts/module/check_module.sh # Update Makefile.depend - ${QPACKAGE_ROOT}/scripts/module/create_Makefile_depend.sh ${QPACKAGE_ROOT}/scripts/module/module_handler.py save_makefile_depend -# save_makefile_depend - # Update EZFIO interface (create the irp.f90 and the ocaml) ${QPACKAGE_ROOT}/scripts/ezfio_interface/ei_handler.py --irpf90 --ocaml @@ -52,6 +49,9 @@ Build failed for module $MODULE # Create png ${QPACKAGE_ROOT}/scripts/module/module_handler.py create_png + # Create png + ${QPACKAGE_ROOT}/scripts/module/update_README.py + cd ${OLDPWD} done ${QPACKAGE_ROOT}/scripts/module/create_executables_list.sh diff --git a/scripts/check_module.sh b/scripts/module/check_module.sh similarity index 100% rename from scripts/check_module.sh rename to scripts/module/check_module.sh diff --git a/scripts/check_src.sh b/scripts/module/check_src.sh similarity index 100% rename from scripts/check_src.sh rename to scripts/module/check_src.sh diff --git a/scripts/module/module_handler.py b/scripts/module/module_handler.py index 597027d8..c47fc639 100755 --- a/scripts/module/module_handler.py +++ b/scripts/module/module_handler.py @@ -25,7 +25,7 @@ from docopt import docopt import os import sys import os.path -from qp_utils import cache +from cache import cache @cache diff --git a/scripts/update_README.py b/scripts/module/update_README.py similarity index 100% rename from scripts/update_README.py rename to scripts/module/update_README.py diff --git a/scripts/qp_utils.py b/scripts/utility/cache.py similarity index 100% rename from scripts/qp_utils.py rename to scripts/utility/cache.py diff --git a/scripts/module/pydot.py b/scripts/utility/pydot.py similarity index 100% rename from scripts/module/pydot.py rename to scripts/utility/pydot.py