Thoughtbot trail - Unix

You can use these commands and operators:
** |, <, >, >>, &, ack, awk, cat, chmod, chown, cp, export, find, kill, locate, ls, mkdir, mv, ps, rm, sed, sort, tail, top, vim, whereis, xargs.**

Found an awesome index resource!

Piping : | direct the input of one command into the input of another
< Take the input from a file into a command

Take the output of a command into a file

“>>” Take the output of a command and append (add it) to the end of a file.
& Added at the end of a command to run the command in the background
ack : Better than grep; advanced search
AWK : A unix shell scripting language to manipulate the streamed row and column data output given within the terminal
cat : Streams the internal data of one* files and outputs them into the terminal
chmod : Changes the read,write and execute permissions of the specified file
chown : Changes the user or group ownership of the file specified
cp : Copies the specified file into another directory and/or replaced file name
export : Instantiate a temporary shell environment variable
Example –# set vim as a text editor
export EDITOR=/usr/bin/bin
find : Current directory file properties search excluding content
“find . -name foo*bar”
This will search from the current directory down for foo*bar (that is, any filename that begins with foo and ends with bar).
kill : Kills the specified process id
locate : Find patterned files by name in the given directory
ls : List the contents of the specified directory; additional flags can change the required output style
mkdir : Make a folder at the specified location
mv : Move the specified file into the new location; can also be used to rename the file and replace its extension
ps : Give information about the running processes in the active shell
(Can be used with grep to display information about a specific process)
rm : Remove a file; commonly used with the -R flag to recursively remove the files within a given directory
sed : Special shell editor used to perform regular expressions on the specified file
sort : List the files in the specified directory with the required context
tail : Show the last 10 lines of the file
top : Real time process activity details
whereis : States the source location of the given file (Binaries and manual sections)
xargs : Performs the given command with additional flags on the standard input including spaces before the pipe.
fg : If a process is running in the background, fg runs it in the foreground.
bg : If a process is running in the foreground, bg runs it in the background.


Now read this

Test Driven Development in Ruby tuts+ course - Stubs and Mocks notes

Stubbing - A technique used in TDD/BDD allowing you to simulate using third party dependencies for your own code. Example, retrieving data from a database, you pass a “splat” = dummy data to a stub. We have no control over what our data... Continue →