linux shell script

arp -d *

n00b
Joined
Feb 16, 2004
Messages
14
i have a shell script i wrote where I type something like:

./npage titlehere > pagename.html

and it makes a html page with the correct title and filename that I told it.

I added at the end so that it does

mv *.html /home/username/web/


how can I change it so it only moves the file I just created and not all html files in that directory?
 
Rather than redirect the script output to a file from the CLI, read arguments from the CLI, create your file inside the script with the specified name, and then move it to the destination. Right now your script is completely unaware that a file is even being created.
 
Back
Top