José Juan’s Reviews > How Linux Works: What Every Superuser Should Know > Status Update
Like flag
José’s Previous Updates
José Juan
is on page 14 of 368
Getting Online Help: man ls; man -k keyword; man -5 passwd; command --help or -h; ls --help; info command; some pkgs dump avail docs into /usr/share/docs with no regard for online manual systems like man of info.
— Aug 14, 2013 02:05PM
José Juan
is on page 13 of 368
Special Chars: Perl uses nearly all of them, *.!|/\$'`"^~#[]{}_; Jargon File, http://www.catb.org/~esr/jargon/html/, The New Hacker's Dictionary[Raymond]; Command-Line Editing: Ctrl-B,Ctrl-F,Ctrl-P,Ctrl-N,Ctrl-A,Ctrl-E,Ctrl-W,Ctrl-U; Text Editors: vi; emacs; Learning the vi Editor[Lamb] book; For emacs, start emacs from prompt, type Ctrl-H and then type t. GNU Emacs Manual[Stallman]
— Aug 14, 2013 02:04PM
José Juan
is on page 11 of 368
passwd - change password, chsh - change shell; Dot Files, .bashrc, .login, .[^.]* or .??* to get all dot files except the current and parent dirs; Environment and Shell Variables, PS1 controls the prompt, STUFF=blah, LESS env var, many man pages contain a section marked ENVIRONMENT that describes env vars, assign env var by export STUFF; PATH=dir:$PATH;
— Aug 14, 2013 02:02PM
José Juan
is on page 9 of 368
more and less
less --help
pwd (print working dir)
diff (option -c)
file
find
find dir -name file -print
head and tail
head /etc/inittab shows first 10 lines
tail /etc/inittab shows last 10 lines
sort (options -n -r)
— Aug 13, 2013 09:37PM
less --help
pwd (print working dir)
diff (option -c)
file
find
find dir -name file -print
head and tail
head /etc/inittab shows first 10 lines
tail /etc/inittab shows last 10 lines
sort (options -n -r)
José Juan
is on page 7 of 368
Further References:
Mastering Regular Expressions[Friedl]
regex chapter of Programming Perl[Wall]
Introduction to Automata Theory, Languages, and Computation[Hopcroft](*like math)
— Aug 13, 2013 09:36PM
Mastering Regular Expressions[Friedl]
regex chapter of Programming Perl[Wall]
Introduction to Automata Theory, Languages, and Computation[Hopcroft](*like math)
José Juan
is on page 7 of 368
See Appendix A for large list of cmds
grep root /etc/passwd
grep root /etc/*
-i and -v options
egrep
regex vs wildcard-style patterns
regex .* match any number of chars like * in wildcards
regex . match one arbitrary char
grep(1) man page describe regex
— Aug 13, 2013 09:35PM
grep root /etc/passwd
grep root /etc/*
-i and -v options
egrep
regex vs wildcard-style patterns
regex .* match any number of chars like * in wildcards
regex . match one arbitrary char
grep(1) man page describe regex
José Juan
is on page 6 of 368
/bin/sh
shell window / terminal windown
prompt $
cat
stdin / stdout
Ctrl D / Ctrl C
Basic cmds: ls, cp, mv, touch, rm, echo
* echo cmd is useful for finding expansions of shell wildcards and variables
/ . and .., absolute and relative pathnames
Directory Cmds: cd, mkdir, rmdir, rm -rf
Shell Wildcards
echo *
echo *dfkdsafh
?
single quotes to escape, echo '*', will find handy in grep and find cmds
— Aug 13, 2013 08:38PM
shell window / terminal windown
prompt $
cat
stdin / stdout
Ctrl D / Ctrl C
Basic cmds: ls, cp, mv, touch, rm, echo
* echo cmd is useful for finding expansions of shell wildcards and variables
/ . and .., absolute and relative pathnames
Directory Cmds: cd, mkdir, rmdir, rm -rf
Shell Wildcards
echo *
echo *dfkdsafh
?
single quotes to escape, echo '*', will find handy in grep and find cmds

