• Some users have recently had their accounts hijacked. It seems that the now defunct EVGA forums might have compromised your password there and seems many are using the same PW here. We would suggest you UPDATE YOUR PASSWORD and TURN ON 2FA for your account here to further secure it. None of the compromised accounts had 2FA turned on.
    Once you have enabled 2FA, your account will be updated soon to show a badge, letting other members know that you use 2FA to protect your account. This should be beneficial for everyone that uses FSFT.

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