I want to create a script that creates a new folder with the name of the first argument in the directory specified as the second argument.
#!/bin/bash -e
Passing Arguments (fastq data and directory where generate the output) into this script
$fastq_file $new_directory
Create the new directory
mkdir $new_directory/$fastq_file
I have also tried mkdir "$new_directory"/"$fastq_file"
After saving and closing
I have tried to run the script with this
my_script 12345.fastq ./
The desired output should be a new folder in the current directory called 12345
If the user instead of my_script 12345.fastq ./
would have been my_script 12345.fastq /home/folder1/folder2
I would like to get a new folder called 12345 in the directory /home/folder1/folder2
However, after many attends I always get the error: mkdir: cannot create directory `/': File exists