diff --git a/common/cal.md b/common/cal.md new file mode 100644 index 0000000000..1733818a49 --- /dev/null +++ b/common/cal.md @@ -0,0 +1,19 @@ +# cal + +> Prints calendar information + +- Display a calendar for the current month or specified month + +`cal` +`cal -m {{12}}` +`cal -m {{Dec}}` + +- Display a calendar for the current year or a specified year + +`cal -y` +`cal 2013` + +- Display date of Easter (western churches) + +`ncal -e` +`ncal -e 2013` \ No newline at end of file diff --git a/common/cp.md b/common/cp.md index fe035a5776..d99ba9ee98 100644 --- a/common/cp.md +++ b/common/cp.md @@ -10,10 +10,12 @@ `cp {{/path/to/original}} ../{{/path/to/copy}}` -- Copy directories recursive using the option -r. +- Copy directories recursive using the option -r. Optionally showing files as they are copied. `cp -r {{/path/to/original}} {{/path/to/copy}}` - -- Copy files in verbose mode, showing files as they are copied. (Mostly interesting with -r option). - `cp -vr {{/path/to/original}} {{/path/to/copy}}` + +- Make a copy of a file adding and extension or changing an extension + +`cp {{file.html}}\{,.backup\}` +`cp file.\{html,backup\}` diff --git a/common/rm.md b/common/rm.md index d3bf1745e7..1d911e3153 100644 --- a/common/rm.md +++ b/common/rm.md @@ -2,7 +2,7 @@ > Remove files or directories -- Remove files from arbitrary +- Remove files from arbitrary locations `rm {{/path/to/file}} {{/otherpath/to/file2}}` @@ -12,4 +12,4 @@ - Prompt before every removal -`rm -i *` \ No newline at end of file +`rm -i {{\*}}` \ No newline at end of file diff --git a/common/srm.md b/common/srm.md new file mode 100644 index 0000000000..e589ffbe10 --- /dev/null +++ b/common/srm.md @@ -0,0 +1,18 @@ +# srm + +> Securely remove files or directories +> Overwrites the existing data one or multiple. Drop in replacement for rm. + +- Removes a file after overwriting (single pass, 7 pass, 35 pass) + +`srm -s {{/path/to/file}}` +`srm -m {{/path/to/file}}` +`srm {{/path/to/file}}` + +- Scurely remove recursively a directory and all it's subdirectories + +`srm -r {{/path/to/folder}}` + +- Prompt before every removal + +`srm -i {{\*}}` \ No newline at end of file diff --git a/linux/md5sum.md b/linux/md5sum.md new file mode 100644 index 0000000000..cda2fb8775 --- /dev/null +++ b/linux/md5sum.md @@ -0,0 +1,13 @@ +# md5sum + +> Calculate MD5 cryptographic checksums + +- Calculate the MD5 checksum for file(s) or files in a directory, one checksum per file + +`md5sum {{filename1}}` +`md5sum {{filename1}} {{filename2}}` +`md5sum {{directory/\*}}` + +- Read a file of MD5SUMs and verify all files have matching checksums + +`md5sum -c {{filename.md5}}` diff --git a/osx/md5.md b/osx/md5.md new file mode 100644 index 0000000000..1b50f1c0a0 --- /dev/null +++ b/osx/md5.md @@ -0,0 +1,13 @@ +# md5 + +> Calculate MD5 cryptographic checksums + +- Calculate the MD5 checksum for file(s) or files in a directory, one checksum per file + +`md5 {{filename1}}` +`md5 {{filename1}} {{filename2}}` +`md5 {{directory/\*}}` + +- Output only the md5 checksum (no filename) + +`md5 -q {{filename}}` diff --git a/osx/xed.md b/osx/xed.md new file mode 100644 index 0000000000..67431f407c --- /dev/null +++ b/osx/xed.md @@ -0,0 +1,16 @@ +# xed + +> Opens files for editing in XCode + +- Open file(s) in XCode + +`xed {{file1}}` +`xed {{/path/to/file1}} {{/path/to/file2}}` + +- Open file(s) in XCode, create if it doesn't exist + +`xed -c {{filename1}}` + +- Open a file in XCode and jump to line number 75 + +`xed -l 75 {{filename}}`