Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

terminal run sh 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
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #terminal #run #sh #file
ADD COMMENT
Topic
Name
4+8 =