I would like to know how I can make a file with a name of a pet as the name of the file with the file not having any thing written on it. What I want is to have a file in the dir where the pet gets downloaded so the it can't get downloaded again once it has been moved.
I am sure there is probably a better way of doing this.
Code: Select all
#!/bin/sh
mkdir /root/Downloads/sfs
cd /root/Downloads/sfs
if [ -f /root/Downloads/sfs/devx_fluxpup_1.5.sfs ]; then
Xdialog --msgbox "All ready downloaded" 0 0
else
rxvt -geometry 130x10+0+0 -bg black -fg green -e wget -4 -t 2 -T 20 http://smokey01.com/Oldyeller/FluxPup/devx_fluxpup_1.5.sfs
Xdialog -title="Move" --yesno "Do you have a savefile" 0 0
if [ $? -eq 0 ]; then
Xdialog -title="Move" --yesno "Do you want to move file to mnt/home" 0 0
if [ $? -eq 0 ]; then
mv /root/Downloads/sfs/devx_fluxpup_1.5.sfs /mnt/home then
Xdialog --msgbox "Finished" 0 0
fi
fi
fi
exit 0