mirror of
https://github.com/mintty/wsltty.git
synced 2025-10-31 23:21:59 +00:00
Add Shortcut and command script variants changing to Linux home directory (#3).
This commit is contained in:
11
install.bat
11
install.bat
@@ -9,8 +9,10 @@ copy LICENSE.wslbridge "%LOCALAPPDATA%\wsltty"
|
||||
copy uninstall.bat "%LOCALAPPDATA%\wsltty"
|
||||
|
||||
copy wsl.bat "%LOCALAPPDATA%\wsltty"
|
||||
copy wsl~.bat "%LOCALAPPDATA%\wsltty"
|
||||
rem does not work without admin rights:
|
||||
rem copy wsl.bat "%SYSTEMROOT%\System32"
|
||||
rem copy wsl~.bat "%SYSTEMROOT%\System32"
|
||||
|
||||
mkdir "%LOCALAPPDATA%\wsltty\bin"
|
||||
copy cygwin1.dll "%LOCALAPPDATA%\wsltty\bin"
|
||||
@@ -29,9 +31,11 @@ mkdir "%LOCALAPPDATA%\wsltty\home\%USERNAME%"
|
||||
|
||||
rem create Desktop Shorcut
|
||||
copy "Bash on UoW in Mintty.lnk" "%USERPROFILE%\Desktop"
|
||||
copy "Bash ~ on UoW in Mintty.lnk" "%USERPROFILE%\Desktop"
|
||||
|
||||
rem create Start Menu Shortcut
|
||||
copy "Bash on UoW in Mintty.lnk" "%APPDATA%\Microsoft\Windows\Start Menu"
|
||||
copy "Bash ~ on UoW in Mintty.lnk" "%APPDATA%\Microsoft\Windows\Start Menu"
|
||||
|
||||
|
||||
:explorer
|
||||
@@ -54,11 +58,12 @@ set shell=/bin/bash
|
||||
rem Mintty invocation
|
||||
set cmd=%LOCALAPPDATA%\wsltty\bin\mintty.exe
|
||||
set cset=-o Locale=C -o Charset=UTF-8
|
||||
set opts=--wsl
|
||||
set icon=%LOCALAPPDATA%\lxss\bash.ico
|
||||
set arg=/bin/wslbridge -t %shell%
|
||||
set target0=\"%cmd%\" %cset% -i \"%icon%\" %arg%
|
||||
rem set target1=\"%cmd%\" %cset% -i \"%icon%\" /bin/dash -c \"cd '%%1'; exec %arg%\"
|
||||
set target1=\"%cmd%\" %cset% -i \"%icon%\" --dir \"%%1\" %arg%
|
||||
set target0=\"%cmd%\" %opts% %cset% -i \"%icon%\" %arg%
|
||||
rem set target1=\"%cmd%\" %opts% %cset% -i \"%icon%\" /bin/dash -c \"cd '%%1'; exec %arg%\"
|
||||
set target1=\"%cmd%\" %opts% %cset% -i \"%icon%\" --dir \"%%1\" %arg%
|
||||
|
||||
reg add "%userdirname%\wsltty" /d "%label% %here%" /f
|
||||
reg add "%userdirname%\wsltty" /v Icon /d "%icon%" /f
|
||||
|
||||
Reference in New Issue
Block a user