/
githubmirror
/
brackets
Обзор
Документация
Войти
/
githubmirror
/
brackets
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
tools/setup_for_hacking.bat
36 строк
1 KB
Andrew Dal Cin
Added brackets around root_path in the mkdir directive of setup_for_hacking to account for user's whose root directory contains spaces
12 фев 2014, 01:30
12 фев 2014, 01:30
6b9ed27
Код
Авторство
О чём код?
@ECHO OFF REM - Use full path of this batch file to determine root directory set root_path=%~f0 set root_path=%root_path:~0,-27% REM - Check for parameter IF %1.==. GOTO Error REM - Check for OS. This script works in Vista or later. ver | findstr /i "5\.1\." > nul IF %ERRORLEVEL% EQU 0 GOTO XPNotSupported REM - Remove existing 'dev' directory (if present) if exist %1\dev rmdir %1\dev REM - Make symlink REM (doesn't work on XP - see instructions below) mklink /d %1\dev "%root_path%" GOTO Exit :Error ECHO Usage: setup_for_hacking.bat application_path ECHO Setup Brackets to use the HTML/CSS/JS files pulled from GitHub. ECHO Parameters: application_path - path that contains the Brackets application ECHO Example: setup_for_hacking.bat "c:\Program Files (x86)\Brackets" GOTO Exit :XPNotSupported ECHO Sorry, this script doesn't run in Windows XP. ECHO To enable hacking, use the junction tool (http://technet.microsoft.com/en-us/sysinternals/bb896768) ECHO as follows: junction.exe %1\dev "%root_path%" ECHO (in the folder containing Brackets.exe) :Exit