Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

how to run a sh file in terminal

# if not already ran, run to change permisions executable.
chmod 755 foo.sh

# then to run the sh file
./foo.sh
Comment

how to create a sh file to run terminal commands

you start with
#!/bin/bash
EnterYourCommand



and open a terminal in the same directory where the .sh file is and run "chmod +x FILENAME.sh"
Comment

linux run .sh in terminal

sh <name of file>.sh
Comment

how to run a .sh file

./yourscript.sh
Comment

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
Comment

how to execute an sh file in linux

./file.sh
Comment

PREVIOUS NEXT
Code Example
Shell :: git abandon untracked files 
Shell :: expo install package version 
Shell :: openssl list certificate chain 
Shell :: git reset a single file to previous commit 
Shell :: open current directory 
Shell :: get ip address linux 
Shell :: bin bash header 
Shell :: How to Install & Run CodeIgniter Framework 
Shell :: scp from local to remote 
Shell :: docker image prune 
Shell :: django start project in existing directory 
Shell :: why gitignore does not work 
Shell :: git ignore all files and folders in folder 
Shell :: why installing pandas take time in docker 
Shell :: gunicorn 
Shell :: django upgrade 
Shell :: open /var/lib/docker/tmp/buildkit-mount140273675/Dockerfile.base: no such file or directory 
Shell :: Copy local repository for remote servers git 
Shell :: conemu git bash 
Shell :: how to install snapd on ubuntu 
Shell :: Find CentOS version and architecture 
Shell :: git submodule 
Shell :: install watchman on linux 
Shell :: sed extract string between two patterns 
Shell :: alpine install package 
Shell :: branch conflicts 
Shell :: journalctl size 
Shell :: grep not include 
Shell :: install newman-reporter-htmlextra 
Shell :: install python 3.6 in colab 
ADD CONTENT
Topic
Content
Source link
Name
3+5 =