This question already has an answer here:
I want my bash script to read parameters from config file. Here is what inside the script:
#!/bin/bash source /home/myscript/conf/config.conf echo "$username"
and below is my config.conf:
The output when I run the script:
[user@machinename bin]$ . thescript : No such file or directoryonfig.conf : command not found jonas
Here I am confused, though it successfully print "jonas", why is there error "No such file or directory" and "command not found"?
Am I doing something wrong?