Skip to content

newtab.cmd calls the CUI-application in the other tab of WindowsTerminal

Notifications You must be signed in to change notification settings

hymkor/newtab.cmd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

newtab.cmd

newtab.cmd calls the CUI-application in the other tab of WindowsTerminal

@echo off
setlocal
if "%1" == "" (
    echo %0: - Start application in the other tab of WindowsTerminal
    echo Usage: %0 COMMANDNAME
    exit /b 0
)
if "%CURRENTDIRECTORY%" == "" (
    for /F %%I in ('cd') do set "CURRENTDIRECTORY=%%I"
    for /F %%I in ('where %1') do @"%LOCALAPPDATA%\Microsoft\WindowsApps\wt.exe" --window 0 new-tab -- %~dpnx0 %%I %2 %3 %4 %5 %6 %7 %8 %9
) else (
    cd "%CURRENTDIRECTORY%"
    %1 %2 %3 %4 %5 %6 %7 %8 %9
)
endlocal
exit /b 0

About

newtab.cmd calls the CUI-application in the other tab of WindowsTerminal

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published