1
0
mirror of https://github.com/mintty/wsltty.git synced 2025-10-31 23:21:59 +00:00

portable installation (#306)

This commit is contained in:
mintty
2022-03-22 00:00:00 +01:00
parent 73fcc66790
commit 4caa2c34eb
5 changed files with 59 additions and 3 deletions

27
install-portable.bat Executable file
View File

@@ -0,0 +1,27 @@
@echo off
set sel="Select folder to place installation of portable wsltty"
for /f "usebackq delims=" %%f in (`powershell "(new-object -COM Shell.Application).BrowseForFolder(0, '%sel%', 0, 0).self.path"`) do set f=%%f
set instdir=%f%\wsltty
if "%f%"=="" (
echo no installation
exit
) else if not exist "%f%" (
echo invalid installation folder %instdir%
exit
)
call install "%instdir%" "%instdir%" /P
rem create shortcut
cd /D "%instdir%"
set instpath=%instdir:~2%
set target=%%COMSPEC%%
set minttyargs=/C bin\mintty.exe --WSL= --icon=/wsl.ico --configdir=. -~
set bridgeargs= -
set wdir=%instpath%
set icon=%instpath%\wsl.ico
cscript /nologo mkshortcut.vbs "/name:WSL Terminal Portable"