Hello I have written a script and I want to schedule it to run at a certain time with the at command. I also want to use an argument in order to pass the time I want in the script so it can be executed at a specific time. The script's name is displaydir and it has the following arguments:
./displaydir dir1 09:00 AM
The script:
#!/bin/bash
at $2 $3
ll $1
cp ./$1/ ./dir2
exit 0