- Java 1.5
java -version
- Download Liquibase
wget http://sourceforge.net/projects/liquibase/files/Liquibase%20Core/liquibase-3.3.0-bin.zip/download -O liquibase-3.3.0-bin.zip
unzip liquibase-3.3.0-bin.zip
cd liquibase-3.3.0-bin.zip
2.Clone this repo
git clone [email protected]:ipij/liquibase.git ./
- (branch step1)
cat liquibase.properties
- create
table1
table in PostgreSQL liquibase diff
liquibase diffChangeLog
- (branch step2) Create files as in step1 branch (such as master.xml)
liquibase --changeLogFile=master.xml updateSQL
liquibase --changeLogFile=master.xml update
liquibase --changeLogFile=master.xml tag 1.0
- drop table1
- (branch step3)
liquibase diffChangeLog
- (branch step4)
liquibase --changeLogFile=master.xml update
liquibase rollback 1.0