From 52ddd10d57155290bad810c768dc55258354901c Mon Sep 17 00:00:00 2001 From: Thomas Allen Christensen II Date: Fri, 24 May 2019 11:21:45 -0600 Subject: [PATCH] Fixed find and xargs to actually work together --- main.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.sh b/main.sh index 27b7cfa..21eb7dc 100644 --- a/main.sh +++ b/main.sh @@ -23,8 +23,8 @@ module load r # Metaxa2 uses 4 cpus, we need to make sure that each instance has # enough cpus to run echo "--^-- X: Reading FASTQ sequences..." -find . -maxdepth 1 -0 -name "*R1_001.fastq.gz" | \ - xargs -L1 -P"$SLURM_NTASKS" srun -n1 -N1 --exclusive ./fastq-to-taxonomy.sh +find . -maxdepth 1 -print0 -name "*R1_001.fastq.gz" | \ + xargs -0 -L1 -P"$SLURM_NTASKS" srun -n1 -N1 --exclusive ./fastq-to-taxonomy.sh echo "--^-- X: Reading FASTQ sequences...Done!" # Compile those pesky individual taxonomic tables into a single @@ -188,4 +188,4 @@ xargs -a catcols.txt -P"$SLURM_NTASKS" -L1 srun -n1 -N1 --exclusive \ xargs -a numcols.txt -P"$SLURM_NTASKS" -L1 srun -n1 -N1 --exclusive \ ./sample-regression.sh -echo "--^-- X: All Done!" \ No newline at end of file +echo "--^-- X: All Done!"