Bash/Linux – Folder Flattening Script (keep X number of subfolders)
A folder flattening script for your files. Takes files and folders in a location & makes the folder tree less deep (if files have same name it will rename a file so thatRead More…
A folder flattening script for your files. Takes files and folders in a location & makes the folder tree less deep (if files have same name it will rename a file so thatRead More…
# echo "thislinehas%allovertheplace%%asdf%%" | awk '{print $0}' thislinehas%allovertheplace%%asdf%% Really quick… the above and below commmand simply tells awk to print the inputed line, so that the output should look as if itRead More…
Use this convertbytes2human function, If you want to convert a number of bytes (for example 43252) or an exponential number number of bytes (such as 1.03e5) to a human readable size. NOTE: sinceRead More…
# Awk is missing ABS – absolute value – so we have to make it. # if you want to do: y=abs(x) # you cant just write the above as abs(x) isRead More…
This will convert a second into a more feasible number split up into parts of hrs/min/sec (or if you want also days and weeks and years) Provided 5 configurations of this converterRead More…
Solaris “ifconfig” and “ifconfig -a” miss out on interesting values like “error” & “drop” etc. netstat and ndd are its replacement in that case # see common stats – usually seen withRead More…