Skip to content

Instantly share code, notes, and snippets.

@stoph
Created February 27, 2015 03:32
Show Gist options
  • Save stoph/6f047380125539f991f6 to your computer and use it in GitHub Desktop.
Save stoph/6f047380125539f991f6 to your computer and use it in GitHub Desktop.
Simple script to quickly reboot your Raspberry Pi
# Reboot script
# mine lives in /usr/local/bin/rb
# be sure to 'sudo chmod +x /usr/local/bin/rb'
#!/bin/bash
read -r -p "Are you sure you want to reboot? [y/N] " response
response=${response,,}
if [[ $response =~ ^(yes|y)$ ]]
then
sudo shutdown -r now
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment