Основни Линук команде на Линук и Виндовс оперативним системима
Ово писање је корисно за оне који желе да започну са Линук команди. Here you will find the most common commands that are used in Linux.
Ако желите да покренете Линук команде на Виндовс онда инсталирајте Цигвин. Цигвин is a Linux layer on top of Windows that allows you to use Linux commands in Windows.
Ако инсталирате на Виндовс Цигвин тада је подразумевани пут када покренете Цигвин терминал ће бити:
C:\cygwin64\home\{username}
Направи нову пример нотепад документ
touch textfile.txt
Промена директоријум
cd {directory path\name}
List directory content in long format ( -l ) including hidden files and directories ( -a )
ls -l -a
ls -al
Order files and directories by the time they were last modified
ls -t
List directory with pause and scrolling
ls -l | less
Схов тренутну локацију (print working directory)
pwd
Екстракт последња 100 речи фајл
tail -100 {filename.extension}
Екстракт први 100 реда датотеке
head -100 {filename.extension}
Копирајте датотеку
cp {source} {destination}
Мове датотеку
mv {source} {destination}
Направите нови директоријум
mkdir {new directory name}
Делете филе
rm {filename}
Delete an empty directory
rmdir {directory to remove}
rm -d{directory to remove}
Delete directory and its contents
rm -r {directory to remove}
rm -R{directory to remove}
Сортирај садржај датотеке
sort {filename to sort}
Уклањање двоструких уноса у датотеци
uniq {filename to remove duplicates}
Цомпресс филес
gzip {filename}
Цомпресс директоријум
gzip -r {directory name}
Тачка број редова и речи у текст фајл
wc {filename}
Search text within files for matching string pattern (case sensitive)
grep 'word' {filename}
Search text within files for matching string pattern (case insensitive)
grep -i 'word' {filename}
Search with a directory
grep -R Arctic /home/ccuser/workspace/geography
Приказ садржај текстуалне датотеке
cat
sed stream editor (similar to find and replace)
sed 's/snow/rain/' forests.txt
Промена фајл и именик дозволе
chmod {options} {permissions} {filename}
Листа недавне команде које се користе
history
Аутоматски распоред задатака
cron
crontab
Промена дозволе филе
chmod {permission number} {some file or directory}
chmod 777 /storage
Промена рекурзивне дозволе за датотеку
chmod -R {permission number} {some file or directory}
