Only walk back to the start of trunk

Change-Id: I54b326f0dfb7ec82aa6ac4d58863adf3608a42e2
This commit is contained in:
Michael Still 2013-12-05 15:31:46 +11:00 committed by Joshua Hesketh
parent 2401b92c76
commit ef0f711e35

View File

@ -160,15 +160,15 @@ db_sync "patchset" $2 $3 $4 $5 $6 $8
version=`mysql -u $4 --password=$5 $6 -e "select * from migrate_version \G" | grep version | sed 's/.*: //'`
echo "Schema version is $version"
echo "Now downgrade all the way back to Folsom"
db_sync "patchset" $2 $3 $4 $5 $6 $8 "--version 133"
target_version=`ls $3/nova/db/sqlalchemy/migrate_repo/versions | head -1 | cut -f 1 -d "_"`
echo "Now downgrade all the way back to the start of trunk (v$target_version)"
db_sync "patchset" $2 $3 $4 $5 $6 $8 "--version $target_version"
# Determine the schema version
version=`mysql -u $4 --password=$5 $6 -e "select * from migrate_version \G" | grep version | sed 's/.*: //'`
echo "Schema version is $version"
echo "And now back up to head from Folsom"
stable_release_db_sync $2 $3 $4 $5 $6
echo "And now back up to head from the start of trunk"
git checkout working
db_sync "patchset" $2 $3 $4 $5 $6 $8