diff --git a/2019_GDB/config/CONFIG.yaml b/2019_GDB/config/CONFIG.yaml
index bb91d499ca7c05359f0144ca6b02e0be38e133dd..aab8911bf4efe9daef1f357fbf111082335ffbd0 100755
--- a/2019_GDB/config/CONFIG.yaml
+++ b/2019_GDB/config/CONFIG.yaml
@@ -1,5 +1,5 @@
 # steps: "assembly_annotation mapping metaT mmseq binning taxonomy analysis"
-steps: "binning taxonomy"
+steps: "binning taxonomy analysis"
 data_dir: "data"
 results_dir: "results"
 db_dir: "dbs"
@@ -91,7 +91,8 @@ rebaler:
     threads: 28
 diamond:
     threads: 28
-    db: "/mnt/isilon/projects/ecosystem_biology/NOMIS/DIAMOND/new_nr.dmnd"
+    #db: "/mnt/isilon/projects/ecosystem_biology/NOMIS/DIAMOND/new_nr.dmnd"
+    db: "/work/projects/ecosystem_biology/local_tools/databases/nr_uniprot_trembl.dmnd"
 metaspades:
     threads: 28
 mmseq2:
@@ -151,3 +152,11 @@ mmseqs:
      createdb: "/home/users/sbusi/apps/mmseqs/bin/mmseqs createdb"
      rbh: "/home/users/sbusi/apps/mmseqs/bin/mmseqs rbh"
      convertalis: "/home/users/sbusi/apps/mmseqs/bin/mmseqs convertalis"
+
+# Paths to CASC and minced for CRISPR
+CASC:
+    PATH: "$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/bin"
+    PERL5LIB: "/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/lib/site_perl"
+
+minced:
+    PATH: "$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/minced/"
diff --git a/2019_GDB/rules/ANALYSIS_RULES b/2019_GDB/rules/ANALYSIS_RULES
index 8ad82ef0ec23162c56e5029ee6332d2803b556ed..da245790fdb6bfb0150950c8d993bd6ef8704eef 100755
--- a/2019_GDB/rules/ANALYSIS_RULES
+++ b/2019_GDB/rules/ANALYSIS_RULES
@@ -165,11 +165,12 @@ rule casc:
     shell:
         """
         (date &&\
-        export PATH=$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/bin &&\
-        export PERL5LIB=/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/lib/site_perl
+        export PATH={config[CASC][PATH]} &&\ 
+        export PERL5LIB={config[CASC][PERL5LIB]} &&\
         casc -i {input} -o $(dirname {output.cas1}) -n 12 --conservative &&\
         echo $(basename -s ".results.txt" {output.cas1}) >> {output.cas2} &&\
-        awk '$8 == "true" {{sum += $2}} END {{print sum}}' {output.cas1} >> {output.cas2} &&\
+#        awk '$8 == "true" {{sum += $2}} END {{print sum}}' {output.cas1} >> {output.cas2} &&\
+        cat {output.cas1}) | awk '$8 == "true" {{sum += $2}} END {{print sum}}' >> {output.cas2} &&\        
         date) &> >(tee {log})
         """
 
@@ -184,7 +185,7 @@ rule minced:
     shell:
         """
         (date &&\
-        export PATH=$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/minced/ &&\
+        export PATH={config[minced][PATH]} &&\
         minced {input} {output.mn1} {output.mn2} &&\
         echo $(basename -s ".txt" {output.mn1}) >> minced_CRISPR_output.txt &&\
         grep -c 'CRISPR' {output.mn1} >> minced_CRISPR_output.txt &&\
diff --git a/config/CONFIG.yaml b/config/CONFIG.yaml
index bb91d499ca7c05359f0144ca6b02e0be38e133dd..aab8911bf4efe9daef1f357fbf111082335ffbd0 100755
--- a/config/CONFIG.yaml
+++ b/config/CONFIG.yaml
@@ -1,5 +1,5 @@
 # steps: "assembly_annotation mapping metaT mmseq binning taxonomy analysis"
-steps: "binning taxonomy"
+steps: "binning taxonomy analysis"
 data_dir: "data"
 results_dir: "results"
 db_dir: "dbs"
@@ -91,7 +91,8 @@ rebaler:
     threads: 28
 diamond:
     threads: 28
-    db: "/mnt/isilon/projects/ecosystem_biology/NOMIS/DIAMOND/new_nr.dmnd"
+    #db: "/mnt/isilon/projects/ecosystem_biology/NOMIS/DIAMOND/new_nr.dmnd"
+    db: "/work/projects/ecosystem_biology/local_tools/databases/nr_uniprot_trembl.dmnd"
 metaspades:
     threads: 28
 mmseq2:
@@ -151,3 +152,11 @@ mmseqs:
      createdb: "/home/users/sbusi/apps/mmseqs/bin/mmseqs createdb"
      rbh: "/home/users/sbusi/apps/mmseqs/bin/mmseqs rbh"
      convertalis: "/home/users/sbusi/apps/mmseqs/bin/mmseqs convertalis"
+
+# Paths to CASC and minced for CRISPR
+CASC:
+    PATH: "$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/bin"
+    PERL5LIB: "/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/lib/site_perl"
+
+minced:
+    PATH: "$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/minced/"
diff --git a/rules/ANALYSIS_RULES b/rules/ANALYSIS_RULES
index 8ad82ef0ec23162c56e5029ee6332d2803b556ed..da245790fdb6bfb0150950c8d993bd6ef8704eef 100755
--- a/rules/ANALYSIS_RULES
+++ b/rules/ANALYSIS_RULES
@@ -165,11 +165,12 @@ rule casc:
     shell:
         """
         (date &&\
-        export PATH=$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/bin &&\
-        export PERL5LIB=/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/lib/site_perl
+        export PATH={config[CASC][PATH]} &&\ 
+        export PERL5LIB={config[CASC][PERL5LIB]} &&\
         casc -i {input} -o $(dirname {output.cas1}) -n 12 --conservative &&\
         echo $(basename -s ".results.txt" {output.cas1}) >> {output.cas2} &&\
-        awk '$8 == "true" {{sum += $2}} END {{print sum}}' {output.cas1} >> {output.cas2} &&\
+#        awk '$8 == "true" {{sum += $2}} END {{print sum}}' {output.cas1} >> {output.cas2} &&\
+        cat {output.cas1}) | awk '$8 == "true" {{sum += $2}} END {{print sum}}' >> {output.cas2} &&\        
         date) &> >(tee {log})
         """
 
@@ -184,7 +185,7 @@ rule minced:
     shell:
         """
         (date &&\
-        export PATH=$PATH:/mnt/lscratch/users/sbusi/ONT/cedric_ont_basecalling/2019_GDB/crispr/minced/ &&\
+        export PATH={config[minced][PATH]} &&\
         minced {input} {output.mn1} {output.mn2} &&\
         echo $(basename -s ".txt" {output.mn1}) >> minced_CRISPR_output.txt &&\
         grep -c 'CRISPR' {output.mn1} >> minced_CRISPR_output.txt &&\