Mercurial > repos > galaxyp > openms_openswathrtnormalizer
annotate generate.sh @ 13:3a841eba4877 draft
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
| author | galaxyp | 
|---|---|
| date | Thu, 27 Aug 2020 22:44:31 +0000 | 
| parents | |
| children | e6dc6d3e3325 | 
| rev | line source | 
|---|---|
| 13 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 1 #!/usr/bin/env bash | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 2 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 3 # VERSION=2.3 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 4 # CONDAPKG=https://anaconda.org/bioconda/openms/2.3.0/download/linux-64/openms-2.3.0-py27h932d754_3.tar.bz2 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 5 # VERSION=2.4 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 6 # CONDAPKG=https://anaconda.org/bioconda/openms/2.4.0/download/linux-64/openms-2.4.0-py27h574aadf_1.tar.bz2 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 7 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 8 VERSION=2.5 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 9 FILETYPES="filetypes.txt" | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 10 PROFILE="20.05" | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 11 ## FILETYPES_RE=$(grep -v "^#" $FILETYPES | grep -v "^$" | cut -f 1 -d" " | tr '\n' '|' | sed 's/|$//'| sed 's/|/\\|/g') | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 12 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 13 export tmp=$(mktemp -d) | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 14 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 15 export CTDCONVERTER="$tmp/CTDConverter" | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 16 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 17 export PYTHONPATH="$(pwd)/CTDopts/" | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 18 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 19 ## reset old data | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 20 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 21 # rm $(ls *xml |grep -v macros) | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 22 # rm -rf ctd | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 23 # mkdir -p ctd | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 24 # echo "" > prepare_test_data.sh | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 25 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 26 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 27 ## generate tests | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 28 ## also creates | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 29 ## - conda environment (for executing the binaries) and | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 30 ## - the git clone of OpenMS (for generating the tests) | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 31 ## - ctd files | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 32 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 33 bash ./test-data.sh ./macros_autotest.xml | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 34 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 35 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 36 ## get the | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 37 ## - conda package (for easy access and listing of the OpenMS binaries), | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 38 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 39 # if [ ! -d $OPENMSPKG ]; then | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 40 # mkdir $OPENMSPKG/ | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 41 # wget -P $OPENMSPKG/ "$CONDAPKG" | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 42 # tar -xf $OPENMSPKG/"$(basename $CONDAPKG)" -C OpenMS$VERSION-pkg/ | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 43 # rm $OPENMSPKG/"$(basename $CONDAPKG)" | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 44 # fi | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 45 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 46 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 47 ## Get python libaries for CTD -> Galaxy conversion | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 48 ## TODO fix to main repo OR conda packkage if PRs are merged | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 49 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 50 # if [ ! -d CTDopts ]; then | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 51 # # git clone https://github.com/genericworkflownodes/CTDopts CTDopts | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 52 # git clone -b topic/no-1-2x https://github.com/bernt-matthias/CTDopts CTDopts | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 53 # fi | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 54 if [ ! -d $CTDCONVERTER ]; then | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 55 #git clone https://github.com/WorkflowConversion/CTDConverter.git CTDConverter | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 56 git clone -b topic/cdata https://github.com/bernt-matthias/CTDConverter.git $CTDCONVERTER | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 57 fi | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 58 # export PYTHONPATH=$(pwd)/CTDopts | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 59 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 60 ## conversion ctd->xml | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 61 ############################################################################### | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 62 source $(dirname $(which conda))/../etc/profile.d/conda.sh | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 63 conda activate $tmp/OpenMS$VERSION-env | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 64 python $CTDCONVERTER/convert.py galaxy -i ctd/*ctd -o ./ -s tools_blacklist.txt -f "$FILETYPES" -m macros.xml -t tool.conf -p hardcoded_params.json --test-macros macros_autotest.xml --test-macros-prefix autotest_ --test-macros macros_test.xml --test-macros-prefix manutest_ --tool-version $VERSION --tool-profile $PROFILE > convert.out 2> convert.err | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 65 if [[ "$?" -ne "0" ]]; then >&2 echo 'CTD -> XML conversion failed'; >&2 echo -e "stderr:\n$(cat convert.err)"; fi | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 66 conda deactivate | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 67 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 68 patch PepNovoAdapter.xml < PepNovoAdapter.patch | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 69 patch OMSSAAdapter.xml < OMSSAAdapter.patch | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 70 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 71 # #-b version log debug test in_type executable pepnovo_executable param_model_directory rt_concat_trafo_out param_id_pool | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 72 | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 73 # for i in A-E F-H I-L M-N O-P Q-Z | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 74 # do | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 75 # planemo t [$i]*xml --galaxy_branch release_20.05 --galaxy_python_version 3.7 --test_output $i.html --test_output_json $i.json & | 
| 
3a841eba4877
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit ddf41e8bda1ba065f5cdec98e93dee8165ffc1b9"
 galaxyp parents: diff
changeset | 76 # done | 
