Skip to content

Instantly share code, notes, and snippets.

@StudioLE
Created January 4, 2015 23:26
Show Gist options
  • Save StudioLE/e3370591d018e832cc89 to your computer and use it in GitHub Desktop.
Save StudioLE/e3370591d018e832cc89 to your computer and use it in GitHub Desktop.
Simple script to backup a minecraft server
#!/bin/bash
echo "Backup LE-CRAFT"
echo "Ensure you have set /save-off or /stop"
echo "Are you ready? [y/n]"
read execute
if [ $execute = y ]
then
echo "Backing up.."
cp -rp "/home/le/lecraft/world" "/home/le/lecraft/backups/world-"$(date +"%F-%H-%M")
echo "Complete"
echo "Remember to set /save-on again"
else
echo "Aborted"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment