Nemokamas konverteris
Linux / Bash Command Cheat Sheet
Išsamus „Linux“ ir „Bash“ komandų apgaulės lapas. Ieškokite daugiau nei 80 pagrindinių komandų su pavyzdžiais, aprašymais ir kopija vienu spustelėjimu.
ls
List directory contents
Pavyzdys:
ls -la /home/userls -la
List all files including hidden, with details
Pavyzdys:
ls -la ~/Documentscd
Change directory
Pavyzdys:
cd /var/logpwd
Print working directory path
Pavyzdys:
pwdmkdir
Create a new directory
Pavyzdys:
mkdir -p /tmp/mydir/subdirrm
Remove files or directories
Pavyzdys:
rm -rf /tmp/oldfilescp
Copy files or directories
Pavyzdys:
cp -r /src/dir /dst/dirmv
Move or rename files/directories
Pavyzdys:
mv oldname.txt newname.txttouch
Create an empty file or update timestamp
Pavyzdys:
touch newfile.txtfind
Search for files in a directory hierarchy
Pavyzdys:
find /home -name '*.log' -mtime -7locate
Find files by name using a prebuilt database
Pavyzdys:
locate nginx.confln
Create hard or symbolic links
Pavyzdys:
ln -s /path/to/target /path/to/linkdf
Report disk space usage of file systems
Pavyzdys:
df -hdu
Estimate file space usage
Pavyzdys:
du -sh /var/log/*stat
Display file or file system status
Pavyzdys:
stat /etc/passwdfile
Determine file type
Pavyzdys:
file /usr/bin/bashcat
Concatenate and display file contents
Pavyzdys:
cat /etc/hostsless
View file content one screen at a time
Pavyzdys:
less /var/log/syslogmore
View file content page by page
Pavyzdys:
more /etc/passwdhead
Output the first part of a file
Pavyzdys:
head -n 20 /var/log/auth.logtail
Output the last part of a file
Pavyzdys:
tail -f /var/log/sysloggrep
Search text using patterns
Pavyzdys:
grep -rn 'error' /var/log/sed
Stream editor for filtering and transforming text
Pavyzdys:
sed 's/old/new/g' file.txtawk
Pattern scanning and text processing language
Pavyzdys:
awk '{print $1, $3}' access.logsort
Sort lines of text files
Pavyzdys:
sort -k2 -n data.txtuniq
Report or omit repeated lines
Pavyzdys:
sort file.txt | uniq -cwc
Print newline, word, and byte counts
Pavyzdys:
wc -l /etc/passwdcut
Remove sections from each line of files
Pavyzdys:
cut -d: -f1 /etc/passwdtr
Translate or delete characters
Pavyzdys:
echo 'hello' | tr 'a-z' 'A-Z'echo
Display a line of text
Pavyzdys:
echo "Hello, World!"printf
Format and print data
Pavyzdys:
printf "%s\t%d\n" name 42diff
Compare files line by line
Pavyzdys:
diff file1.txt file2.txttee
Read from stdin and write to stdout and files
Pavyzdys:
ls | tee output.txtps
Report a snapshot of current processes
Pavyzdys:
ps aux | grep nginxtop
Display Linux processes in real time
Pavyzdys:
top -u www-datahtop
Interactive process viewer (ncurses-based)
Pavyzdys:
htopkill
Send a signal to a process
Pavyzdys:
kill -9 1234killall
Kill processes by name
Pavyzdys:
killall firefoxbg
Resume a suspended job in the background
Pavyzdys:
bg %1fg
Bring a job to the foreground
Pavyzdys:
fg %1jobs
List active jobs in the current shell
Pavyzdys:
jobs -lnohup
Run a command immune to hangups
Pavyzdys:
nohup ./script.sh &nice
Run a command with modified scheduling priority
Pavyzdys:
nice -n 10 ./heavy_task.shsystemctl
Control the systemd system and service manager
Pavyzdys:
systemctl restart nginxservice
Run a System V init script
Pavyzdys:
service apache2 statusping
Send ICMP ECHO_REQUEST to network hosts
Pavyzdys:
ping -c 4 google.comcurl
Transfer data from or to a server
Pavyzdys:
curl -L -o file.zip https://example.com/file.zipwget
Non-interactive network downloader
Pavyzdys:
wget -q https://example.com/file.tar.gzssh
OpenSSH remote login client
Pavyzdys:
ssh -i ~/.ssh/key.pem user@hostscp
Secure copy files between hosts
Pavyzdys:
scp user@host:/path/file.txt ./local/rsync
Remote file copying tool with delta transfer
Pavyzdys:
rsync -avz /src/ user@host:/dst/netstat
Print network connections and routing tables
Pavyzdys:
netstat -tulpnss
Utility to investigate sockets
Pavyzdys:
ss -tulwnifconfig
Configure a network interface
Pavyzdys:
ifconfig eth0ip
Show and manipulate routing, devices, and tunnels
Pavyzdys:
ip addr shownmap
Network exploration tool and port scanner
Pavyzdys:
nmap -sV 192.168.1.0/24dig
DNS lookup utility
Pavyzdys:
dig +short A google.comnslookup
Query Internet name servers interactively
Pavyzdys:
nslookup example.comchmod
Change file mode bits (permissions)
Pavyzdys:
chmod 755 script.shchown
Change file owner and group
Pavyzdys:
chown -R www-data:www-data /var/wwwchgrp
Change group ownership
Pavyzdys:
chgrp developers project/sudo
Execute a command as another user (superuser)
Pavyzdys:
sudo systemctl restart nginxsu
Change user ID or become superuser
Pavyzdys:
su - postgrespasswd
Change user password
Pavyzdys:
passwd usernameumask
Set or display the file mode creation mask
Pavyzdys:
umask 022id
Print user and group information
Pavyzdys:
id usernamewhoami
Print the current effective user name
Pavyzdys:
whoamigroups
Print the groups a user is in
Pavyzdys:
groups usernametar
Archive files using tape archive format
Pavyzdys:
tar -czvf archive.tar.gz /path/to/dirtar -x
Extract files from a tar archive
Pavyzdys:
tar -xzvf archive.tar.gz -C /target/gzip
Compress files using GNU zip
Pavyzdys:
gzip -9 large_file.loggunzip
Decompress gzip compressed files
Pavyzdys:
gunzip archive.tar.gzzip
Package and compress files into a ZIP archive
Pavyzdys:
zip -r output.zip /path/to/dirunzip
Extract files from a ZIP archive
Pavyzdys:
unzip archive.zip -d /target/bzip2
Compress files using bzip2 algorithm
Pavyzdys:
bzip2 -z large_file.txtxz
Compress files using the XZ algorithm
Pavyzdys:
xz -z -9 file.txtuname
Print system information
Pavyzdys:
uname -auptime
Tell how long the system has been running
Pavyzdys:
uptimefree
Display amount of free and used memory
Pavyzdys:
free -hlscpu
Display information about the CPU architecture
Pavyzdys:
lscpulsblk
List information about block devices
Pavyzdys:
lsblk -o NAME,SIZE,TYPE,MOUNTPOINTlspci
List all PCI devices
Pavyzdys:
lspci -v | grep VGAdmesg
Print or control the kernel ring buffer
Pavyzdys:
dmesg | tail -50journalctl
Query and display messages from the journal
Pavyzdys:
journalctl -u nginx --since '1 hour ago'history
Display the command history list
Pavyzdys:
history | grep dockerenv
Print environment variables
Pavyzdys:
env | grep PATHif / then / fi
Conditional execution in shell scripts
Pavyzdys:
if [ -f file.txt ]; then echo exists; fifor
Loop over a list of items
Pavyzdys:
for i in 1 2 3; do echo $i; donewhile
Execute commands while a condition is true
Pavyzdys:
while read line; do echo $line; done < filecase
Multi-branch conditional matching pattern
Pavyzdys:
case "$var" in a) echo A;; b) echo B;; esacfunction
Define a shell function
Pavyzdys:
greet() { echo "Hello, $1!"; }; greet Worldexport
Set environment variables for child processes
Pavyzdys:
export MY_VAR=valuesource
Execute commands from a file in current shell
Pavyzdys:
source ~/.bashrcalias
Create an alias for a command
Pavyzdys:
alias ll='ls -la'cron / crontab
Schedule commands to run periodically
Pavyzdys:
crontab -e # 0 * * * * /path/to/script.shat
Execute commands at a specified time
Pavyzdys:
echo 'ls /tmp' | at 14:30Susiję įrankiai
Peržiūrėti visus įrankiusGit komandos Cheat Sheet
Išsamus Git komandos apgaulės lapas. Ieškokite daugiau nei 80 pagrindinių „Git“ komandų su pavyzdžiais, aprašymais ir kopija vienu spustelėjimu.
Docker komandos Cheat Sheet
Išsamus „Docker“ komandų apgaulės lapas. Ieškokite daugiau nei 70 pagrindinių „Docker“ komandų su pavyzdžiais, aprašymais ir kopijavimo vienu spustelėjimu.
Vim komandos Cheat Sheet
Išsamus Vim komandos apgaulės lapas. Ieškokite daugiau nei 80 pagrindinių Vim komandų su pavyzdžiais, aprašymais ir kopija vienu spustelėjimu.
SQL formatuoklis & Gražintuvas
Savo naršyklėje akimirksniu formatuokite, pagražinkite ir išvalykite SQL užklausas. Įkelti nereikia – visiškai privatu ir nemokama.