#!/bin/bash # specify the QP folder QP=$QP_ROOT dir=${QP} # sourcing the quantum_package.rc file . ${QP}/quantum_package.rc # script that copy all data from |AO| basis and nuclei of EZFIO_extra to the ao_extra_basis and extra_nuclei of EZFIO_target # use: # qp_copy_extra_basis EZFIO_extra EZFIO_target EZFIO_extra=${1%/} EZFIO_extra=${EZFIO_extra%.xyz} EZFIO_target=${2%/} echo "********** SCRIPT TO COPY DATA FROM EZFIO TO ANOTHER *********" echo "Extracting data from "$EZFIO_extra echo "and Copying data to "$EZFIO_target ### COPYING ALL DATA FROM $EZFIO_extra/nuclei/ to ${EZFIO_target}/extra_nuclei/ echo "COPYING ALL DATA FROM "$EZFIO_extra"/nuclei/ to "${EZFIO_target}"/extra_nuclei/" direxists=false if [ -d ${EZFIO_target}/extra_nuclei/ ] ; then direxists=true echo "The directory extra_nuclei exists" else echo "Creating the directory extra_nuclei " direxists=false mkdir ${EZFIO_target}/extra_nuclei/ fi data=`\ls $EZFIO_extra/nuclei/` for i in $data do echo $i newfile=`echo $i | sed 's/nucl/extra_nucl/g' ` echo $newfile cp ${EZFIO_extra}/nuclei/$i ${EZFIO_target}/extra_nuclei/$newfile done ### COPYING ALL DATA FROM $EZFIO_extra/ao_basis/ to ${EZFIO_target}/ao_extra_basis/ direxists=false if [ -d ${EZFIO_target}/ao_extra_basis/ ] ; then direxists=true echo "The directory exists ao_extra_basis" else echo "Creating the directory ao_extra_basis" direxists=false mkdir ${EZFIO_target}/ao_extra_basis/ fi echo "COPYING ALL DATA FROM "$EZFIO_extra"/ao_basis/ to "${EZFIO_target}"/ao_extra_basis/" data=`\ls $EZFIO_extra/ao_basis/` for i in $data do echo $i newfile=`echo $i | sed 's/ao/ao_extra/g' ` echo $newfile cp ${EZFIO_extra}/ao_basis/$i ${EZFIO_target}/ao_extra_basis/$newfile done i=primitives_normalized newfile=primitives_normalized_extra cp ${EZFIO_extra}/ao_basis/$i ${EZFIO_target}/ao_extra_basis/$newfile echo "COPYING ALL DATA FROM "$EZFIO_extra"/aux_quantities/ to "${EZFIO_target}"/ao_extra_basis/" i=data_one_e_dm_tot_ao.gz newfile=ao_extra_one_e_dm.gz cp ${EZFIO_extra}/aux_quantities/$i ${EZFIO_target}/ao_extra_basis/$newfile