1
0
mirror of https://github.com/mintty/wsltty.git synced 2025-01-31 10:11:02 +00:00
wsltty/install.bat

62 lines
1.7 KiB
Batchfile
Raw Normal View History

2016-11-16 16:46:50 +01:00
@echo off
2016-09-14 14:55:14 +02:00
rem If you change the installation directory,
rem it also needs to be adapted in
rem - the Shortcut links *.lnk
rem - the cmd invocation scripts wsl*.bat
2016-11-16 16:46:50 +01:00
set installdir=%LOCALAPPDATA%\wsltty
:deploy
2016-09-14 14:55:14 +02:00
mkdir "%installdir%"
copy LICENSE.mintty "%installdir%"
copy LICENSE.wslbridge "%installdir%"
copy uninstall.bat "%installdir%"
copy wsl.bat "%installdir%"
copy wsl~.bat "%installdir%"
2016-11-16 16:46:50 +01:00
copy wsl-l.bat "%installdir%"
2016-11-18 00:17:56 +01:00
copy "config-context-menu.bat" "%installdir%"
copy "add to context menu.lnk" "%installdir%"
copy "remove from context menu.lnk" "%installdir%"
2016-09-19 00:46:51 +02:00
rem does not work without admin rights:
rem copy wsl.bat "%SYSTEMROOT%\System32"
rem copy wsl~.bat "%SYSTEMROOT%\System32"
2016-11-16 16:46:50 +01:00
rem copy wsl-l.bat "%SYSTEMROOT%\System32"
2016-09-19 00:46:51 +02:00
mkdir "%installdir%\bin"
copy cygwin1.dll "%installdir%\bin"
copy cygwin-console-helper.exe "%installdir%\bin"
rem copy dash.exe "%installdir%\bin"
copy mintty.exe "%installdir%\bin"
copy wslbridge.exe "%installdir%\bin"
copy wslbridge-backend "%installdir%\bin"
2016-09-14 14:55:14 +02:00
rem create "home directory" to enable storage of config file
mkdir "%installdir%\home
mkdir "%installdir%\home\%USERNAME%"
2016-09-14 14:55:14 +02:00
:shortcuts
2016-11-16 16:46:50 +01:00
rem create Start Menu Folder
set smf=%APPDATA%\Microsoft\Windows\Start Menu\Programs\WSLtty
mkdir "%smf%"
2016-11-18 00:17:56 +01:00
echo on
2016-11-16 16:46:50 +01:00
copy "wsltty home & help.url" "%smf%"
2016-11-18 00:17:56 +01:00
copy "WSL Bash %% in Mintty.lnk" "%smf%"
2016-11-16 16:46:50 +01:00
copy "WSL Bash ~ in Mintty.lnk" "%smf%"
copy "WSL Bash -l in Mintty.lnk" "%smf%"
mkdir "%smf%\context menu shortcuts"
2016-11-18 00:17:56 +01:00
copy "add to context menu.lnk" "%smf%\context menu shortcuts"
copy "remove from context menu.lnk" "%smf%\context menu shortcuts"
2016-11-16 16:46:50 +01:00
rem create Desktop Shorcuts
2016-11-18 00:17:56 +01:00
copy "WSL Bash %% in Mintty.lnk" "%USERPROFILE%\Desktop"
2016-11-16 16:46:50 +01:00
copy "WSL Bash ~ in Mintty.lnk" "%USERPROFILE%\Desktop"
2016-09-14 14:55:14 +02:00
:end