diff --git a/common/cksum.md b/common/cksum.md new file mode 100644 index 000000000..e3e3f81b8 --- /dev/null +++ b/common/cksum.md @@ -0,0 +1,8 @@ +# cksum + +> Calculates CRC checksums and byte counts of a file +> Note, on old UNIX systems the CRC implementation may differ. + +- Display a 32 checksum, size in bytes and filename + +`chksum {{filename}}` diff --git a/common/touch.md b/common/touch.md new file mode 100644 index 000000000..beda03021 --- /dev/null +++ b/common/touch.md @@ -0,0 +1,16 @@ +# touch + +> Change a file access and modification times (atime, mtime) + +- Create a new empty file(s) or change the times for existing file(s) to current time.` + +`touch {{filename}}` + +- Set the times on a file to those specified + +`touch -t 201412250801.59 {{filename}} +`touch -t {{YYYYMMDDHHMM.SS}} {{filename}} + +- Set the times on a file to match those on second file + +`touch -r {{filename2}} {{filename}}` diff --git a/common/uname.md b/common/uname.md new file mode 100644 index 000000000..bf89716a1 --- /dev/null +++ b/common/uname.md @@ -0,0 +1,15 @@ +# uname + +> Print operating system name + +- Print all available operating system and kernel information + +`uname -a` + +- Print the current operating system name (e.g. Linux, Darwin, SunOS, etc) + +`uname -s` + +- Print the nodename (hostname) of the system + +`uname -n` diff --git a/common/which.md b/common/which.md new file mode 100644 index 000000000..6d5327d30 --- /dev/null +++ b/common/which.md @@ -0,0 +1,12 @@ +# which + +> Locate the a program in the user's path + +- Display the path of an executable program + +`which {{ls}}` +`which {{executable}}` + +- If there are multiple executables which match, display all + +`which -a {{executable}}` diff --git a/osx/sw_vers.md b/osx/sw_vers.md new file mode 100644 index 000000000..977636a85 --- /dev/null +++ b/osx/sw_vers.md @@ -0,0 +1,12 @@ +# sw_vers + +> Print Mac OSX Software versioning information + +- Print OSX Version + +`sw_vers -productVersion` + +- Print OSX Build + +`sw_vers -buildVersion` +