Skip to content

Latest commit

 

History

History
34 lines (26 loc) · 1.05 KB

README.md

File metadata and controls

34 lines (26 loc) · 1.05 KB

BuildMySpace

A simple batch file for Windows which will launch your workspace

If you don't want to waste your time everyday starting your workspace (even if it's 35,58sec) and if you work on Windows you can:

  1. Open your favorite text editor
  2. add some batch lines (it will be explained thereafter)
  3. save as bat file
  4. double click on the file
  5. Work !

How to write the script ?

these lines will look for your program, check if it's running, if not, will start it.

tasklist /FI "IMAGENAME eq MyProgram.exe" 2>NUL | find /I /N "MyProgram.exe">NUL
if "%ERRORLEVEL%"=="0" (
	echo Program is running
) else (
	start "MyProgram" "pathToMyProgram.exe"
)

Tips:

  • You can replace 2>NUL by 2>myFilePath.txtto keep track.
  • Starting many apps may crash or slow down your machine, to prevent this you can add SLEEP 5or ping -n 2 localhost >nul between each start

What next ?

  • save program's names in a list
  • use a loop to found the file and start the program
  • write a script for linux

More information here : http://ss64.com/