Skip to content

Ethical-h4ckers/bash

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 

Repository files navigation

This repo will contain complete tutorial about bash

Pre-requests

  • a terminal
  • bash or zsh installed

Introduction


Shell Scripting is mainly used to automate taks with the help of shell scripting language and Bash is the most used of em' Bash is the default shell in allmost all linux operating systems


Type Following on any terminal

$ echo $BASH_VERSION

this will print current version of bash you are using

alt-text

Important thing to note You can get full usage of almost any command in linux usig --help option with sometimes -h also works and do the same eg:

> pwd --help

output

pwd: pwd [-LP]
    Print the name of the current working directory.                                                                                                            Options:
      -L        print the value of $PWD if it names the current working directory
      -P        print the physical directory, without any symbolic links

    By default, `pwd' behaves as if `-L' were specified.
                                                                                  Exit Status:
    Returns 0 unless an invalid option is given or the current directory
    cannot be read

Basic commands

Normaly bash program will be situated under the /bin folder where almost all the user executable programs contains you can take a look at what inside that folder by

$ ls /bin

so we used ls to list all the files

ls

we can give some arguments to the ls command which will produce diffrent outputs for example "-S" argument combined with ls will show you the size of that file

All commands used

File Related commands

Commands Description
ls List all the files in the current directry
pwd Print the name of the current working directory
cd change the current working directry
mv move files to directories or rename files
cp copy files to directories

***Linux programs found in /bin

Command Description
2to3-2.7
2to3-3.11
Magick++-config
MagickCore-config
MagickWand-config
UnicodeNameMappingGenerator
[
aarch64-linux-android-clang
aarch64-linux-android-clang++
aarch64-linux-android-cpp
aarch64-linux-android-g++
aarch64-linux-android-gcc
ab
adb
add-trusted-certificate
addpart
alarm
alrecord
altonegen
am
analyze-build
animate
annotate
apachectl
append2simg
apr-1-config
apropos
apt
apt-cache
apt-config
apt-get
apt-key
apt-mark
apu-1-config
apxs
arp
ascii-xfr
aspell
aspell-import
attr
avbtool
awk
b2sum
base32
base64
basename
basenc
bash
bat
bc
bdftogd
blkdiscard
blkid
blkzone
blockdev
bmon
brotli
bugpoint
bundle
bundler
bunzip2
bzcat
bzcmp
bzdiff
bzgrep
bzip2
bzip2recover
bzless
bzmore
c++
cairo-trace
cal
capsh
captest
captoinfo
cat
cc
chcon
chcpu
checkgid
chgrp
chkfont
chmod
choom
chown
chroot
chrt
chsh
cksum
clang
clang++
clang++-15
clang-15
clang-apply-replacements
clang-change-namespace
clang-check
clang-cl
clang-cpp
clang-doc
clang-extdef-mapping
clang-format
clang-include-fixer
clang-linker-wrapper
clang-move
clang-nvlink-wrapper
clang-offload-bundler
clang-offload-packager
clang-offload-wrapper
clang-pseudo
clang-query
clang-refactor
clang-rename
clang-reorder-fields
clang-repl
clang-scan-deps
clang-tidy
clangd
clear
cmd
cmp
cmus
cmus-remote
col
colcrt
colrm
column
comm
compare
compile_et
composite
conjure
convert
corelist
corepack
coreutils
cp
cpan
cpp
csplit
ctrlaltdel
curl
curl-config
cut
cwebp
dalvikvm
dash
date
dbmmanage
dbus-cleanup-sockets
dbus-daemon
dbus-launch
dbus-monitor
dbus-run-session
dbus-send
dbus-test-tool
dbus-update-activation-environment
dbus-uuidgen
dc
dd
dec265
delpart
delv
demandoc
df
diagtool
dialog
diff
diff3
dig
dir
dircolors
dirname
display
dmesg
dnsdomainname
dos2unix
dpkg
dpkg-deb
dpkg-divert
dpkg-fsys-usrunmess
dpkg-query
dpkg-realpath
dpkg-split
dpkg-trigger
drill
dsymutil
du
dumpsexp
dvtm
dvtm-status
dwebp
e2fsdroid
easy_install-2.7
echo
ed
editor
egrep
elinks
enc2xs
encguess
env
envvars
envvars-std
erb
exa
expand
expr
exr2aces
exrenvmap
exrheader
exrinfo
exrmakepreview
exrmaketiled
exrmultipart
exrmultiview
exrstdattr
ext2simg
factor
fallocate
false
fastboot
fcgistarter
fd
ffmpeg
ffprobe
fftw-wisdom
fftw-wisdom-to-conf
fftwf-wisdom
fftwl-wisdom
fgrep
figlet
figlist
file
filecap
fincore
find
find-all-symbols
findfs
flex
flex++
flock
fmt
fold
fortune
free
freetype-config
fribidi
fsck
fsck.cramfs
fsck.minix
fsfreeze
fsmon
ftp
funzip
fuser
fzf
fzf-tmux
g++
gawk
gawkbug
gcc
gd2copypal
gd2togif
gd2topng
gdbm_dump
gdbm_load
gdbmtool
gdcmpgif
gdk-pixbuf-csource
gdk-pixbuf-pixdata
gdk-pixbuf-query-loaders
gdparttopng
gdtopng
gem
getcap
getfattr
getopt
getpcaps
getprop
gh
gif2webp
giftogd2
git
git-clang-format
git-receive-pack
git-upload-archive
git-upload-pack
git2_cli
gotop
gotty
gpg-error
gpg-error-config
gpgrt-config
gpgv
grep
groups
gss-client
gss-server
gunzip
gzexe
gzip
h2ph
h2xs
hardlink
head
hexdump
hmac256
hmaptool
host
hostname
htcacheclean
htdbm
htdigest
htpasswd
httpd
httxt2dbm
hwclock
id
identify
idn2
ifconfig
img2simg
img2sixel
img2webp
import
infocmp
infotocap
install
instmodsh
intercept-build
ionice
ipmaddr
iptunnel
irb
irqtop
ischroot
isosize
jar
jarsigner
java
javac
javadoc
javap
jcmd
jconsole
jdb
jdeprscan
jdeps
jfr
jhsdb
jimage
jinfo
jlink
jmap
jmod
join
jpackage
jps
jq
jrunscript
jshell
json_pp
jstack
jstat
jstatd
k5srvutil
kadmin
kadmin.local
kadmind
kdb5_util
kdestroy
keytool
kill
killall
kinit
klist
kpasswd
kprop
kpropd
kproplog
krb5-config
krb5-send-pr
krb5kdc
ksu
kswitch
ktutil
kvno
lazygit
ld.lld
ld64.lld
ldattach
ldns-config
less
lessecho
lesskey
libassuan-config
libgcrypt-config
libnetcfg
libpng-config
libpng16-config
libsixel-config
link
links
linux32
linux64
live-server
llc
lld
lld-link
lli
llvm-addr2line
llvm-ar
llvm-as
llvm-bcanalyzer
llvm-bitcode-strip
llvm-c-test
llvm-cat
llvm-cfi-verify
llvm-config
llvm-cov
llvm-cvtres
llvm-cxxdump
llvm-cxxfilt
llvm-cxxmap
llvm-debuginfod
llvm-debuginfod-find
llvm-diff
llvm-dis
llvm-dlltool
llvm-dwarfdump
llvm-dwarfutil
llvm-dwp
llvm-exegesis
llvm-extract
llvm-gsymutil
llvm-ifs
llvm-install-name-tool
llvm-jitlink
llvm-lib
llvm-libtool-darwin
llvm-link
llvm-lipo
llvm-lto
llvm-lto2
llvm-mc
llvm-mca
llvm-ml
llvm-modextract
llvm-mt
llvm-nm
llvm-objcopy
llvm-objdump
llvm-opt-report
llvm-otool
llvm-pdbutil
llvm-profdata
llvm-profgen
llvm-ranlib
llvm-rc
llvm-readelf
llvm-readobj
llvm-reduce
llvm-remark-size-diff
llvm-rtdyld
llvm-sim
llvm-size
llvm-split
llvm-stress
llvm-strings
llvm-strip
llvm-symbolizer
llvm-tapi-diff
llvm-tblgen
llvm-tli-checker
llvm-undname
llvm-windres
llvm-xray
ln
logcat
logger
login
logname
logresolve
look
losetup
lpadd
lpdump
lpflash
lpmake
lpunpack
ls
lsblk
lscpu
lsfd
lsipc
lsirq
lsof
lua
lua5.3
luac
luac5.3
lzcat
lzcmp
lzdiff
lzegrep
lzfgrep
lzgrep
lzless
lzma
lzmadec
lzmainfo
lzmore
m4
mac2unix
magick
magick-script
make
makewhatis
man
mandoc
mcookie
md5sum
menu
mii-tool
minicom
mkbootimg
mkdir
mkdtboimg
mke2fs.android
mkfifo
mkfs
mkfs.bfs
mkfs.cramfs
mkfs.minix
mknod
mkswap
mktemp
modularize
mogrify
montage
more
mpc
mpd
mpicalc
mutt
mutt_pgpring
mv
namei
nameif
nano
ncat
ncdu
ncmpcpp
ncursesw6-config
neomutt
neovim-node-host
neovim-ruby-host
netcap
netstat
nfs-cat
nfs-cp
nfs-ls
nfs-stat
nice
nl
nmap
nmon
node
nohup
notmuch
nping
npm
nproc
npth-config
npx
nsenter
nslookup
nsupdate
numfmt
nvim
od
onig-config
openal-info
openssl
opt
pa-info
pacat
pacmd
pactl
pamon
pandoc
pango-list
pango-segmentation
pango-view
paplay
parec
parecord
partx
passwd
paste
pasuspender
patch
pathchk
pcre-config
pcre2-config
pdfattach
pdfdetach
pdffonts
pdfimages
pdfinfo
pdfseparate
pdftk
pdftocairo
pdftohtml
pdftoppm
pdftops
pdftotext
pdfunite
peaclock
peekfd
perl
perlbug
perldoc
perlivp
perlthanks
pgpewrap
pgrep
piconv
pidof
ping
ping6
pip
pip2
pip2.7
pip3
pip3.11
pkg
pkg-config
pkill
pl2pm
play
plipconfig
pm
pmap
pngtogd
pngtogd2
pod2html
pod2man
pod2text
pod2usage
podchecker
pp-trace
pr
precat
preunzip
prezip
prezip-bin
printenv
printf
prlimit
prove
prtstat
ps
pscap
pslog
pspell-config
pstree
ptar
ptardiff
ptargrep
ptx
pulseaudio
pup
pwait
pwd
pwdx
pwlogin
pydoc
pydoc2
pydoc2.7
pydoc3
pydoc3.11
python
python-config
python2
python2-config
python2.7
python2.7-config
python3
python3-config
python3.11
python3.11-config
racc
rake
ranger
rarp
rbs
rdbg
rdoc
readlink
readprofile
realpath
rec
red
rename
renice
repack_bootimg
reset
resizepart
rev
rifle
rm
rmdir
rmiregistry
rotatelogs
route
rsvg-convert
rtcwake
ruby
run-clang-tidy
run-parts
run-with-aspell
runcon
runscript
sancov
sanstats
savelog
scalar
scan-build
scan-build-py
scan-view
sclient
scp
scpa
script
scriptlive
scriptreplay
sdiff
sed
seq
serialver
setarch
setcap
setfattr
setpriv
setsid
setterm
settings
sftp
sftpa
sh
sha1sum
sha224sum
sha256sum
sha384sum
sha512sum
shasum
showfigfonts
shred
shuf
sim_client
sim_server
simg2img
sixel2png
sl
slattach
sleep
smime_keys
soelim
sort
source-ssh-agent
sox
soxi
splain
split
split-file
sserver
ssh
ssh-add
ssh-agent
ssh-copy-id
ssh-keygen
ssh-keyscan
ssha
sshd
start-stop-daemon
stat
stdbuf
strace
strace-log-merge
stream
streamzip
stty
su
sudo
suexec
sum
swaplabel
sync
sysctl
tabs
tac
taglib-config
tail
tar
task
taskset
tee
telnet
tempfile
tere
termimage
test
tftp
tic
tig
timeout
tload
tmux
toe
top
touch
tput
tr
tree
tree-sitter
true
truncate
tset
tsort
tsu
tty
typeprof
uclampset
ul
uname
uname26
unbound
unbound-anchor
unbound-checkconf
unbound-control
unbound-control-setup
unbound-host
uncompress
unexpand
uniq
unix2dos
unix2mac
unlink
unlzma
unpack_bootimg
unshare
unxz
unzip
unzipsfx
unzstd
update-alternatives
uptime
uuclient
uuserver
vdir
verify-uselistorder
vi
vmstat
vtm
w3m
w3mman
wasm-ld
watch
wc
wdctl
webpinfo
webpmux
webpng
wget
whatis
whereis
which
whoami
wipefs
word-list-compress
xapian-config
xargs
xdg-open
xminicom
xml2-config
xslt-config
xsubpp
xxh128sum
xxh32sum
xxh64sum
xxhsum
xz
xzcat
xzcmp
xzdec
xzdiff
xzegrep
xzfgrep
xzgrep
xzless
xzmore
yarn
yarnpkg
yat2m
yes
zcat
zcmp
zdiff
zegrep
zellij
zfgrep
zforce
zgrep
zip
zipcloak
zipdetails
zipgrep
zipinfo
zipnote
zipsplit
zmore
znew
zramctl
zsh
zstd
zstdcat
zstdgrep
zstdless
zstdmt

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published