Created
September 26, 2013 21:30
-
-
Save nsfmc/6720866 to your computer and use it in GitHub Desktop.
saves my old appengine datastore and replaces it with a new one
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function upgrade_datastore () { | |
local ds_source="${HOME}/Dropbox/Khan Academy All Staff/Other shared items/datastores" | |
local ds_target="${HOME}/projects/.gae" | |
local backup_name="current.sqlite $(date "+%Y-%m-%d %H.%M.%S")" | |
mv "${ds_target}/current.sqlite" "${ds_target}/${backup_name}" | |
cp "${ds_source}/current.sqlite" "${ds_target}/" | |
echo "Copied new current.sqlite from dropbox" | |
echo "Your old current.sqlite has been archived at " | |
echo " ${fg[yellow]}${ds_target}/${backup_name}" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment