Last active
March 24, 2016 12:50
-
-
Save maik-s/bec8f17df159b61d4264 to your computer and use it in GitHub Desktop.
this is a simple batch wrapper for creating new batch shortcuts placed in lpath. usage: `create name "path"`
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
set LNAME=%1 | |
set LDIR="%2%" | |
set LPATH=C:/users/name/path/to/dir | |
set LEXT=.cmd | |
set FILENAME=%LPATH%%LNAME%%LEXT% | |
if not exist FILENAME ( | |
echo @echo off > "%FILENAME%" | |
echo cd "%LDIR%" >> "%FILENAME%" | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment