Ichinisan
Lifer
I know perfectly well how to restart explorer.exe via the command line. I've actually done it a lot over the past few weeks (since Systernals Process Monitor somehow trashed itself *and* the Windows Task Manager). It's long past time to reinstall Windows on my work computer and jump from XP to 7 🙂
I don't remember what I was looking for when I came across instructions to create this batch file:
Ignoring all the dumb / irritating things about this, I want to find out more about this part:
" > NUL 2>&1"
I know ">NUL" suppresses output from the screen without sending it to a file. What's going on with the part I underlined? The "&1" seems similar to "%0", "%1", "%2", etc (used for accepting input parameters).
...and here's what I find irritating:
[edit]
I guess the ampersand combines two commands on a single line. I still don't know what's going on with "2>&1"
I don't remember what I was looking for when I came across instructions to create this batch file:
Code:
@echo off
color 0B
echo JumpStart! v0.1 by Scotch
echo.
echo Your desktop is being restored, Please wait. . .
ping -n 5 127.0.0.1 > NUL 2>&1
echo Killing process Explorer.exe. . .
taskkill /f /im explorer.exe
cls
echo Success!
echo.
echo Your desktop is now loading. . .
ping -n 5 127.0.0.1 > NUL 2>&1
echo.
ping -n 5 127.0.0.1 > NUL 2>&1
start explorer.exe
exit
Ignoring all the dumb / irritating things about this, I want to find out more about this part:
" > NUL 2>&1"
I know ">NUL" suppresses output from the screen without sending it to a file. What's going on with the part I underlined? The "&1" seems similar to "%0", "%1", "%2", etc (used for accepting input parameters).
...and here's what I find irritating:
- It uses the PING command only to show a message with mandatory delays. It does it before killing explorer.exe and before it launches explorer.exe (why add delays for no damn reason?!)
- There are two 5-ping delays added before starting explorer.exe (if you think the delay is needed, use a single 10-ping delay)
- "color 0B" is completely unnecessary.
[edit]
I guess the ampersand combines two commands on a single line. I still don't know what's going on with "2>&1"
Last edited: