Check These Out
This should probably only be used for testing in a dev environment as it's not terribly efficient, but if you're doing something that might trash a DB and you still want the old data available, this works like a charm.
If you know the URL of a file on a SharePoint server, it's just a matter of logging in with your AD credentials to get the file with cURL
Outputs Windows Services service name and display name using "sc query", pipes the output to "awk" for processing, then "column" for formatting.
List All Services:
$ sc query state= all | awk '/SERVICE_NAME/{printf"%s:",$2;getline;gsub(/DISP.*:\ /,"");printf"%s\n",$0}' | column -ts\:
List Started Services:
$sc query | awk '/SERVICE_NAME/{printf"%s:",$2;getline;gsub(/DISP.*:\ /,"");printf"%s\n",$0}' | column -ts\:
List Stopped Services:
$sc query state= inactive| awk '/SERVICE_NAME/{printf"%s:",$2;getline;gsub(/DISP.*:\ /,"");printf"%s\n",$0}' | column -ts\:
swap out "80" for your port of interest. Can use port number or named ports e.g. "http"
Another option is openssl.
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"
}
Gives you a list for all installed chrome (chromium) extensions with URL to the page of the extension.
With this you can easy add a new Bookmark folder called "extensions" add every URL to that folder, so it will be synced and you can access the names from every computer you are logged in.
------------------------------------------------------------------------------------------------------------------
Only tested with chromium, for chrome you maybe have to change the find $PATH.
Returns a JSON object, by connecting to the 'test' endpoint of the Twitter API. Simplest way to check if you can connect to Twitter. Output also available in XML, use '/help/test.xml' for that
rpm, sometimes, is not wildcard friendly. To search files installed from package this could be useful.
change PACKAGENAME to any package do you want to search