I have a script to copy the files from one location to another where i am passing the first location as parameter to the script
#!/bin/bash
locatn=$1
echo $locatn
cp -r /locatn/ /ws/priyapan-rcd/workspace/automation/
but when i run this code this throws error as cp: cannot stat `locatn': No such file or directory what could be the issue
locatnin the root directory, use this to refer in the current directory like this:cp -r ./locatn/ /ws/priyapan-rcd/workspace/automation/, note the dot which has been addedcp -r ${locatn} /ws/priyapan-rcd/workspace/automation/no?