I'm trying to make a batch file that copies my firefox bookmarks to my desktop. I'd like to be able to use this with any computer, so I'm trying to find a way to either autodetect which user is logged in, or have an input area in the batch file for me to type a username.
So far this is my code:
@ECHO OFF
Title Copying Firefox Bookmarks
ECHO Are you sure you wish to copy Firefox's bookmarks?
ECHO Y/N?
SET /p play=
IF %play% EQU y GOTO start
IF %play% EQU n EXIT
:start
ECHO This program is currently set to copy bookmarks for user: (username) to the desktop.
ECHO To change this, edit this code and change "(username)" to the correct username.
PAUSE
CLS
ECHO Copying Bookmarks.
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks..
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks...
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks.
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks..
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks...
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks.
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks..
PING localhost n -.5 >nul
CLS
ECHO Copying Bookmarks...
PING localhost n -.5 >nul
CLS
XCOPY "C:\Documents and Settings\(username)\Application Data\Mozilla\Firefox\Profiles\e0nu0mbl.default\bookmarks.html" "C:\Documents and Settings\(username)\Desktop"
PING localhost n -10 >nul
CLS
ECHO Bookmarks have been copied.
PING localhost n -10 >nul
PAUSE
Note that where it says (username) it actually has my username.
I'm trying to find a way to make something like "Please Input Username: _" that will automatically alter the copy/save locations.
Anyone got something that will help?
By the way, I might want an approval thing that says something like
"Files will be copied to C:\Documents and Settings\(username)\Desktop, is this okay?
Y/N"
That last bit isn't necessary, but I would like it.