Skip to content

Instantly share code, notes, and snippets.

@jonny-novikov
Created August 25, 2016 19:57
Show Gist options
  • Save jonny-novikov/fca7af15dc19ad64e9ab09be9120fb95 to your computer and use it in GitHub Desktop.
Save jonny-novikov/fca7af15dc19ad64e9ab09be9120fb95 to your computer and use it in GitHub Desktop.
Takes Postgresql schema dump and runs apgdiff tool to save the diff in a file.
pg_dump -U perkdsp -svf "production_schema.sql" perkdsp
pg_dump -U perkdsp -svf "staging_schema.sql" perkdsp_staging
java -jar apgdiff-2.4.jar production_schema.sql staging_schema.sql > diff.sql
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment