Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

terminal run batch file

#Tested on Win11
# Run script from current directory in current Terminal window/tab:
	./myfile.bat
	# "./" stands for "current directory"

# Run from specific path in a new tab:
	wt C:my foldermyfile.bat
    # You don't need to wrap the path in quotes

# Run from specific path in current window but split the pane (See 2 terminals at once):
	wt split-pane C:my foldermyfile.bat
    
#To learn more args for the wt command go here:
	https://docs.microsoft.com/en-us/windows/terminal/command-line-arguments?tabs=windows#options-and-commands
Comment

How can i get batch files to run through the new window terminal

Open the Registry Editor and navigate to this key:

> ComputerHKEY_CLASSES_ROOTatfileshellopencommand
> Then modify the (Default) value to the following:
> wt.exe -w 0 new-tab -d . -p "Command Prompt" "%1" %*
Comment

PREVIOUS NEXT
Code Example
Shell :: how to add new line to each line 
Shell :: Install Deno - Scoop (Windows) 
Shell :: Correct Folder Permissions Ubuntu 18.04 Server 
Shell :: kali linux ffuf fuzzingvirtual hosts 
Shell :: sed wrap each line in quotes 
Shell :: install stegsnow ubuntu 
Shell :: how to see running commands linux 
Shell :: How can you install Flutter? 
Shell :: bash leerzeichen entfernen 
Shell :: git reset deinit and update submodule and re clone all submodules 
Shell :: open first image in directory linux 
Shell :: docfetcher ubuntu 
Shell :: how to install anbox on ubuntu 18.04 
Shell :: vim append to line 
Shell :: vim move terminal down 
Shell :: deploy contract on bsc testnet hardhat 
Shell :: homebrew gnu screen 
Shell :: example use & 
Shell :: winmerge command line generate report 
Shell :: ubuntu uninstall twilio quest 
Shell :: tmux resume 
Shell :: find drive D windows sub system linuc 
Shell :: telnet in shell script 
Shell :: kubectl delete pods wildcard 
Shell :: delete freebsd account 
Shell :: Bash script to use getopts to get multiple values from user 
Shell :: how to install or renew https ssl in frappe bench 
Shell :: How to install monaca font in Ubuntu 
Shell :: gatsby typescript 
Shell :: scp send folder 
ADD CONTENT
Topic
Content
Source link
Name
9+5 =