Check These Out
swap out "80" for your port of interest. Can use port number or named ports e.g. "http"
Converts any number of seconds into days, hours, minutes and seconds.
sec2dhms() {
declare -i SS="$1"
D=$(( SS / 86400 ))
H=$(( SS % 86400 / 3600 ))
M=$(( SS % 3600 / 60 ))
S=$(( SS % 60 ))
[ "$D" -gt 0 ] && echo -n "${D}:"
[ "$H" -gt 0 ] && printf "%02g:" "$H"
printf "%02g:%02g\n" "$M" "$S"
}
Finds all symbolic links in the specified directory which match the specified string pattern.
I used this when upgrading from an Apple-supported version of Java 6 (1.6.0_65) to an Oracle-supported version (1.7.0_55) on Mac OS X 10.8.5 to find out which executables were pointing to /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands (Apple version) vs. /Library/Java/JavaVirtualMachines/jdk1.7.0_55.jdk/Contents/Home/bin (Oracle version). However, it appears the current JDK installation script already takes care of modifying the links.
Einstein's razor: As simple as possible, but not simpler.
On the destination machine netcat listens on any port (1234 in the example) and sends anything it receives into a file or pipe. On the source machine a separate netcat takes input from a file or pipe and sends it over the network to the listener.
This is great between machines on a LAN where you don't care about authentication, encryption, or compression and I would recommend it for being simpler than anything else in this situation. Over the internet you should use something with better security.
ItemsListtoAvoid (A) could be a list of files with a special characteristic to exclude. It can be a result of previous processing list, ex. a list of files containing a special string.
AlItemsList.txt (B) Is a complete list of items including some or all items in A.
$Difference is saved in ItemsDifference.txt
This command can be used to extract the title defined in HTML pages
-n reads input, line by line, in a loop sending to $_ Equivalent to while () { mycode }
-e execute the following quoted string (i.e. do the following on the same line as the perl command)
the elipses .. operator behaves like a range, remembering the state from line to line.
Slug the part of an URL which identifies a page using human-readable keywords. Slugs are used to construct friendly URLs (often for permalinks) that are easy to type, descriptive, and easy to remember.