Shell Script from Beginners Guide to Shell Scripting Not Working


I went through the steps to make the datecp shell script in this article:

But when I try to run it it tells me that datecp is not a command, even though I’m typing it the way the article says to. Did I do something wrong?


Yatri may have left out an important part. Linux does not search the current directory for commands, so if the current directory (.) is not in the search path, then you need to specify it explictly, Llike this:



That works! Thanks a bunch!