Besplatni pretvarač

Linux / Bash Varalica za naredbe

Sveobuhvatna šifra za Linux i Bash naredbe. Pretražujte 80+ bitnih naredbi s primjerima, opisima i kopijom jednim klikom.

ls
List directory contents
Primjer:ls -la /home/user
ls -la
List all files including hidden, with details
Primjer:ls -la ~/Documents
cd
Change directory
Primjer:cd /var/log
pwd
Print working directory path
Primjer:pwd
mkdir
Create a new directory
Primjer:mkdir -p /tmp/mydir/subdir
rm
Remove files or directories
Primjer:rm -rf /tmp/oldfiles
cp
Copy files or directories
Primjer:cp -r /src/dir /dst/dir
mv
Move or rename files/directories
Primjer:mv oldname.txt newname.txt
touch
Create an empty file or update timestamp
Primjer:touch newfile.txt
find
Search for files in a directory hierarchy
Primjer:find /home -name '*.log' -mtime -7
locate
Find files by name using a prebuilt database
Primjer:locate nginx.conf
ln
Create hard or symbolic links
Primjer:ln -s /path/to/target /path/to/link
df
Report disk space usage of file systems
Primjer:df -h
du
Estimate file space usage
Primjer:du -sh /var/log/*
stat
Display file or file system status
Primjer:stat /etc/passwd
file
Determine file type
Primjer:file /usr/bin/bash
cat
Concatenate and display file contents
Primjer:cat /etc/hosts
less
View file content one screen at a time
Primjer:less /var/log/syslog
more
View file content page by page
Primjer:more /etc/passwd
head
Output the first part of a file
Primjer:head -n 20 /var/log/auth.log
tail
Output the last part of a file
Primjer:tail -f /var/log/syslog
grep
Search text using patterns
Primjer:grep -rn 'error' /var/log/
sed
Stream editor for filtering and transforming text
Primjer:sed 's/old/new/g' file.txt
awk
Pattern scanning and text processing language
Primjer:awk '{print $1, $3}' access.log
sort
Sort lines of text files
Primjer:sort -k2 -n data.txt
uniq
Report or omit repeated lines
Primjer:sort file.txt | uniq -c
wc
Print newline, word, and byte counts
Primjer:wc -l /etc/passwd
cut
Remove sections from each line of files
Primjer:cut -d: -f1 /etc/passwd
tr
Translate or delete characters
Primjer:echo 'hello' | tr 'a-z' 'A-Z'
echo
Display a line of text
Primjer:echo "Hello, World!"
printf
Format and print data
Primjer:printf "%s\t%d\n" name 42
diff
Compare files line by line
Primjer:diff file1.txt file2.txt
tee
Read from stdin and write to stdout and files
Primjer:ls | tee output.txt
ps
Report a snapshot of current processes
Primjer:ps aux | grep nginx
top
Display Linux processes in real time
Primjer:top -u www-data
htop
Interactive process viewer (ncurses-based)
Primjer:htop
kill
Send a signal to a process
Primjer:kill -9 1234
killall
Kill processes by name
Primjer:killall firefox
bg
Resume a suspended job in the background
Primjer:bg %1
fg
Bring a job to the foreground
Primjer:fg %1
jobs
List active jobs in the current shell
Primjer:jobs -l
nohup
Run a command immune to hangups
Primjer:nohup ./script.sh &
nice
Run a command with modified scheduling priority
Primjer:nice -n 10 ./heavy_task.sh
systemctl
Control the systemd system and service manager
Primjer:systemctl restart nginx
service
Run a System V init script
Primjer:service apache2 status
ping
Send ICMP ECHO_REQUEST to network hosts
Primjer:ping -c 4 google.com
curl
Transfer data from or to a server
Primjer:curl -L -o file.zip https://example.com/file.zip
wget
Non-interactive network downloader
Primjer:wget -q https://example.com/file.tar.gz
ssh
OpenSSH remote login client
Primjer:ssh -i ~/.ssh/key.pem user@host
scp
Secure copy files between hosts
Primjer:scp user@host:/path/file.txt ./local/
rsync
Remote file copying tool with delta transfer
Primjer:rsync -avz /src/ user@host:/dst/
netstat
Print network connections and routing tables
Primjer:netstat -tulpn
ss
Utility to investigate sockets
Primjer:ss -tulwn
ifconfig
Configure a network interface
Primjer:ifconfig eth0
ip
Show and manipulate routing, devices, and tunnels
Primjer:ip addr show
nmap
Network exploration tool and port scanner
Primjer:nmap -sV 192.168.1.0/24
dig
DNS lookup utility
Primjer:dig +short A google.com
nslookup
Query Internet name servers interactively
Primjer:nslookup example.com
chmod
Change file mode bits (permissions)
Primjer:chmod 755 script.sh
chown
Change file owner and group
Primjer:chown -R www-data:www-data /var/www
chgrp
Change group ownership
Primjer:chgrp developers project/
sudo
Execute a command as another user (superuser)
Primjer:sudo systemctl restart nginx
su
Change user ID or become superuser
Primjer:su - postgres
passwd
Change user password
Primjer:passwd username
umask
Set or display the file mode creation mask
Primjer:umask 022
id
Print user and group information
Primjer:id username
whoami
Print the current effective user name
Primjer:whoami
groups
Print the groups a user is in
Primjer:groups username
tar
Archive files using tape archive format
Primjer:tar -czvf archive.tar.gz /path/to/dir
tar -x
Extract files from a tar archive
Primjer:tar -xzvf archive.tar.gz -C /target/
gzip
Compress files using GNU zip
Primjer:gzip -9 large_file.log
gunzip
Decompress gzip compressed files
Primjer:gunzip archive.tar.gz
zip
Package and compress files into a ZIP archive
Primjer:zip -r output.zip /path/to/dir
unzip
Extract files from a ZIP archive
Primjer:unzip archive.zip -d /target/
bzip2
Compress files using bzip2 algorithm
Primjer:bzip2 -z large_file.txt
xz
Compress files using the XZ algorithm
Primjer:xz -z -9 file.txt
uname
Print system information
Primjer:uname -a
uptime
Tell how long the system has been running
Primjer:uptime
free
Display amount of free and used memory
Primjer:free -h
lscpu
Display information about the CPU architecture
Primjer:lscpu
lsblk
List information about block devices
Primjer:lsblk -o NAME,SIZE,TYPE,MOUNTPOINT
lspci
List all PCI devices
Primjer:lspci -v | grep VGA
dmesg
Print or control the kernel ring buffer
Primjer:dmesg | tail -50
journalctl
Query and display messages from the journal
Primjer:journalctl -u nginx --since '1 hour ago'
history
Display the command history list
Primjer:history | grep docker
env
Print environment variables
Primjer:env | grep PATH
if / then / fi
Conditional execution in shell scripts
Primjer:if [ -f file.txt ]; then echo exists; fi
for
Loop over a list of items
Primjer:for i in 1 2 3; do echo $i; done
while
Execute commands while a condition is true
Primjer:while read line; do echo $line; done < file
case
Multi-branch conditional matching pattern
Primjer:case "$var" in a) echo A;; b) echo B;; esac
function
Define a shell function
Primjer:greet() { echo "Hello, $1!"; }; greet World
export
Set environment variables for child processes
Primjer:export MY_VAR=value
source
Execute commands from a file in current shell
Primjer:source ~/.bashrc
alias
Create an alias for a command
Primjer:alias ll='ls -la'
cron / crontab
Schedule commands to run periodically
Primjer:crontab -e # 0 * * * * /path/to/script.sh
at
Execute commands at a specified time
Primjer:echo 'ls /tmp' | at 14:30

O ovom alatu

Sveobuhvatni kratki vodič za linux bash. Pregledajte najčešće korištene naredbe, sintaksu i primjere organizirane po kategorijama. Pretraživa i prilagođena mobilnim uređajima — označite ovu stranicu za trenutni pristup kada trebate brzi podsjetnik.

Kako koristiti

  1. Pregledajte kategorizirane referentne odjeljke.
  2. Koristite traku za pretraživanje da pronađete određene naredbe ili sintaksu.
  3. Kliknite na bilo koji unos kako biste vidjeli primjere korištenja i objašnjenja.
  4. Kopirajte naredbe izravno za korištenje u vašem terminalu ili editoru.

Često postavljana pitanja

Je li ova referenca ažurirana?
Referenca pokriva široko korištene naredbe i sintaksu koje su stabilne među verzijama. Za najnovije dodatke ili značajke specifične za verziju provjerite službenu dokumentaciju.
Mogu li ovo koristiti izvan mreže?
Nakon učitavanja stranica radi bez internetske veze. Označite ga za brzi pristup — sav sadržaj se prikazuje u pregledniku bez daljnjih mrežnih zahtjeva.
Je li ovo sveobuhvatno ili samo osnove?
Pokriva najčešće korištene naredbe i obrasce koji obrađuju 90% svakodnevnih zadataka. Za posebne ili napredne značajke pogledajte službenu dokumentaciju.
Mogu li predložiti dodatke?
Redovito ažuriramo naše reference. Ako primijetite da nedostaju naredbe ili imate prijedloge, javite nam putem naše kontakt stranice.