Linux Commands - Part 1

This is a linux command line reference for common operations (part 1).
Examples marked with • are valid/safe to paste without modification into a terminal, so
you may want to keep a terminal window open while reading this so you can cut & paste.
All these commands have been tested both on Fedora and Ubuntu.

Linux Commands - part 1   Command Description • apropos whatis Show commands pertinent to string. See also threadsafe • man -t man | ps2pdf - > man.pdf make a pdf of a manual page   which command Show full path name of command   time command See how long a command takes • time cat See how long a command takes • nice info Run a low priority command (The "info" reader in this case) • renice 19 -p $$ Make shell (script) low priority. Use for non interactive tasks   dir navigation   • cd - Go to previous directory • cd Go to $HOME directory   (cd dir && command) Go to dir, execute command and return to current dir • pushd . Put current dir on stack so you can popd back to it   file searching   • alias l='ls -l --color=auto' quick dir listing • ls -lrt List files by date. See also newest and find_mm_yyyy • ls /usr/bin | pr -T9 -W$COLUMNS Print in 9 columns to width of terminal   find -name '*.[ch]' | xargs grep -E 'expr' Search 'expr' in this dir and below. See also findrepo   find -type f -print0 | xargs -r0 grep -F 'example' Search all regular files for 'example' in this dir and below   find -maxdepth 1 -type f | xargs grep -F 'example' Search all regular files for 'example' in this dir   find -maxdepth 1 -type d | while read dir; do echo $dir; echo cmd2; done Process each item with multiple commands (in while loop) • find -type f ! -perm -444 Find files not readable by all (useful for web site) • find -type d ! -perm -111 Find dirs not accessible by all (useful for web site) • locate -r 'file[^/]*\.txt' Search cached index for names. This re is like glob *file*.txt • look reference Quickly search (sorted) dictionary for prefix • grep --color reference /usr/share/dict/words Highlight occurances of regular expression in dictionary


Sursa
2009-02-21 15:59:28



Comenteaza





Ultimele 25 posturi adăugate

14:20:03Loteria Națională a Moldovei, dublu câștigător la Blask Awards —» Sandu GRECU
04:44:00DIN POEZIA LUMII —» Leo Butnaru
17:27:00ÎN BAZA TRISTEI EXPERIENȚE ISTORICE —» Leo Butnaru
10:04:00TREI PĂRINȚI: MAMA, TATA ȘI BIBLIOTECA —» Leo Butnaru
05:34:00CONCURS PENTRU PĂRINȚI —» Leo Butnaru
17:55:32Hau! Ce surpriză ne făcură elvețienii! —» APort | "Pentru un român care știe citi, cel mai greu lucru e să nu scrie." I.L. Carag
12:20:35Un nou Macbeth pe scena teatrului chișinăuian —» Biblioteca de Arte 'Tudor Arghezi'
05:41:00DIN PASIENȚE —» Leo Butnaru
22:15:49AI, Ai, ai, ce muzică! —» APort | "Pentru un român care știe citi, cel mai greu lucru e să nu scrie." I.L. Carag
19:45:12Te cunosc după cercei, Lolito! —» APort | "Pentru un român care știe citi, cel mai greu lucru e să nu scrie." I.L. Carag
11:23:00Atenție la tentativele de fraudă online. Informați-vă exclusiv din sursele oficiale ale Loteriei Naționale a Moldovei —» Sandu GRECU
11:09:58Prea mult zgomot —» Jurnal A.
06:11:09DIN YES-EURI —» Leo Butnaru
18:04:14Vânturile, Valurile, ediția din 25.01.2026 —» Leo Butnaru
07:52:00Biblioteca raională l-a omagiat pe Mihai Eminescu printr-o serie de activități culturale dedicate Zilei Naționale a Culturii —» BPR Ungheni's Blog
05:02:00POEME DIN EUPHORION —» Leo Butnaru
21:35:35Carlo Masala – If Russia wins —» APort | "Pentru un român care știe citi, cel mai greu lucru e să nu scrie." I.L. Carag
19:41:52Ilie Todorov, actor de teatru și film, regizor și pedagog —» Biblioteca de Arte 'Tudor Arghezi'
06:35:00PENTRU SĂNĂTATEA DUMNEAVOASTRĂ —» Leo Butnaru
11:50:00Vocea fiecăruia dintre noi contează: Raportează corupția la 1520 —» Sandu GRECU
10:49:08Nou: Mileștii Mici Riesling Brut Natur —» Fine Wine
08:09:00DINSPRE HOMER SPRE NOI —» Leo Butnaru
10:59:00UN YES-EU —» Leo Butnaru
07:00:00DIN POEZIA FRANCEZĂ MODERNĂ —» Leo Butnaru
14:57:18Agresat la adunare aur în Suedia (priviți integral) —» Curaj.TV | Media alternativă