Hints: a random selection of trivia

  • System information:
    memory (total; available) in /proc/meminfo ; CPU in /proc/cpuinfo ; 'uname -a' returns all info
  • Redirecting both stdout and stderr with >&‹filename›;
    e.g. to preserve a writing script alive on closing the session:
    nohup ‹my_command› >&‹file› &
  • Updating LaTeX tree:
    % sudo mkdir -p /usr/local/texlive/texmf-local/tex/latex/XXX
    % sudo cp *.sty *.cls /usr/local/texlive/texmf-local/tex/latex/XXX
    % sudo mkdir -p /usr/local/texlive/texmf-local/bibtex/bst/XXX
    % sudo cp *.bst /usr/local/texlive/texmf-local/bibtex/bst/XXX
    % sudo mktexlsr
  • Show Unix directory tree structure:
    ls -R | grep ":$" | sed -e 's/:$//' -e 's/[^-][^\/]*\//--/g' -e 's/^/ /' -e 's/-/|/'
    (or, details at http://www.centerkey.com/tree/