Check These Out
This says if the LHC has destroyed the world. Run it in a loop to monitor the state of Earth. Might not work reliable, if the world has actually been destroyed.
You can ask repeatedly for a non-blank password using this function:
function read_password() {
while [ ! -n "$USER_PASSWORD" ]; do
read -s -p"Password: " USER_PASSWORD
if [ ! -n "$USER_PASSWORD" ]; then
echo "ERROR: You must specify a valid password, please try again"
fi
echo
done
}
Also you can set a time out (in seconds) to write the password
read -t 10 -s -p"Password: " USER_PASSWORD_VARIABLE
if [ ! $? -eq 0 ]; then
echo "Time out!"
fi
Quick method of isolating filenames from a full path using expansion.
Much quicker than using "basename"
If you still connect to your wireless access point manually and need to use wpa_supplicant, the above fu will grep all of the known SSID from your wpa_supplicant.conf file, present it in a Zenity list and return the SSID name you choose. I've wrapped this command in to a bash script that then up's the interface, associates and autenticates. Saves me from using NetworkManager ;)
The command is useful when, e.g., booting an existing system with a rescue or installation CD where you need to chroot into the hard-disk and be able to do stuff which accesses kernel info (e.g. when installing Ubuntu desktop with LVM2 you need to mount and chroot the hard disk from a shell window in order to install packages and run initramfs inside chroot).
The command assumes that /mnt/xxx is where the chroot'ed environment's root file system on the hard disk is mounted.
Friday is the 5th day of the week, monday is the 1st.
Output may be affected by locale.
populate the auth.hosts file with a list of IP addresses that are authorized to be in use and when you run this command it will return the addresses that are pingable and not in the authorized list.
Can be combined with the "Command line Twitter" command to tweet unauthorized access.
this command limit the speed to 8 until next eject of your cdrom disc , can be usefulll when you don't want to listen the sound of your cdrom driver .