From 5fbab058d3fdb5d62efc698e19f9af51057be5d8 Mon Sep 17 00:00:00 2001 From: thkuo Date: Sun, 11 Jul 2021 12:08:15 +0200 Subject: [PATCH] fix installation paths --- README.md | 10 +++++----- denovo/lib/install_perl_mods.sh | 1 + install/SETENV.sh | 3 --- main/S2G | 2 +- main/main_gui.py | 2 +- 5 files changed, 8 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 8e5175c10..593a805cd 100644 --- a/README.md +++ b/README.md @@ -79,9 +79,9 @@ The command uses **--recurse-submodules** to download the submodules. The flag i ``` cd install/ -SETENV.sh snakemake_env +./SETENV.sh snakemake_env conda activate snakemake_env -TESTING.sh +./TESTING.sh ``` ### Usage and Input @@ -187,7 +187,7 @@ To only create the folder and config files, please turn off the last six options The folder *examples/* includes a structured zip file and a yaml file--the two input formats that Seq2Geno can recognize. The zip file can be used as the input with this command: ``` -S2G -z examples/example_input.zip\ +S2G -z examples/example_input/seq2geno_input.yml\ -l examples/example_input_zip.log\ --outzip g2p ``` @@ -197,7 +197,7 @@ is, the zip file) and edit the yaml file to ensure the right paths to those example data. After they are ready, please run with this command: ``` -S2G -f examples/seq2geno_input.yml\ +S2G -f examples/example_input/seq2geno_input.yml\ -l exapmles/seq2geno_input_yml.log\ --outzip g2p ``` @@ -209,7 +209,7 @@ To include automatic submission to the Geno2Pheno server, just use the flag `--to_gp`: ``` -S2G -f examples/seq2geno_input.yml\ +S2G -f examples/example_input/seq2geno_input.yml\ -l exapmles/seq2geno_input_yml.log\ --outzip g2p --to_gp ``` diff --git a/denovo/lib/install_perl_mods.sh b/denovo/lib/install_perl_mods.sh index 6af256412..9858dd69d 100755 --- a/denovo/lib/install_perl_mods.sh +++ b/denovo/lib/install_perl_mods.sh @@ -10,6 +10,7 @@ cpanm --force XML::Parser cpanm --force Graph cpanm --force Graph::Writer::Dot cpanm --force File::Find::Rule +cpanm --force Exception::Class #cpanm Bio::Perl #cpanm Moose #cpanm Log::Log4perl diff --git a/install/SETENV.sh b/install/SETENV.sh index 7159289d8..62b3dfbc7 100755 --- a/install/SETENV.sh +++ b/install/SETENV.sh @@ -82,9 +82,6 @@ conda activate $core_env_name || source activate $core_env_name set_core_env_vars || { echo "Errors in setting up the core environment"; exit; } # Finalize -export SEQ2GENO_HOME=$( dirname $( dirname $( realpath ${BASH_SOURCE[0]} ) ) ) -export PATH=$SEQ2GENO_HOME:$SEQ2GENO_HOME/main:$PATH - cat $SEQ2GENO_HOME/main/S2G| sed "s/_core_env/$core_env_name/g" \ > $SEQ2GENO_HOME/S2G chmod +x $SEQ2GENO_HOME/S2G diff --git a/main/S2G b/main/S2G index c26052575..12d3c5b5c 100644 --- a/main/S2G +++ b/main/S2G @@ -1,7 +1,7 @@ #!/usr/bin/env bash # activate the environment -source _core_env || conda activate _core_env +source activate _core_env || conda activate _core_env if [ $# -eq 0 ];then seq2geno_gui else diff --git a/main/main_gui.py b/main/main_gui.py index 3e1778f9f..3cbec22a9 100755 --- a/main/main_gui.py +++ b/main/main_gui.py @@ -264,7 +264,7 @@ def write_yaml(func_dict, config_dict): initialdir='.') if len(yml_f) > 0: primary_dict['yml_f'].set(yml_f) - with LoadFile(yml_f) as yml_fh: + with open(yml_f, 'w') as yml_fh: yaml.safe_dump(arg_dict, yml_fh) return(yml_f)