All-the-way-down

Issue #25 new
Matthew Butcher created an issue

Would you be open to creating a command (or adding a flag) that would run the down hooks on all of the migrations?

What I'm thinking of is a way to revert the DB all the way back to its original state, which is useful both for testing the database migrations from scratch, and for running integration tests on apps that use goose databases.

Comments (3)

  1. Liam Staskawicz repo owner

    Yes - I think this would be good. I haven't had time to review in depth and merge/implement a few of the existing requests, but I think this functionality would be covered by #17, which proposes the ability to specify a target revision to migrate to.

    I would prefer to take that slightly more general approach, rather than making a specific 'all-the-way-down' command.

  2. Matthew Butcher reporter

    Yeah, if #17 allowed specifying a target by name (and not by index), that would work well. I'd like that.

    Thanks.

  3. Log in to comment