elixir-lang/ecto — pull request #260 by drewolson (2014-08-18 21:33:45+00:00)
Title: Use postgres database when running psql commands for ecto.create and ecto.drop.

Rather than relying on the default database, I think we should specify the `postgres` database for the `ecto.create` and `ecto.drop` mix tasks. This is similar to the strategy used by rails[1].

Perhaps this is something that could be configurable in the future?

I didn't see an obvious way to test this change, but I did test it locally by specifying this repo as a local dependency and using the create/drop tasks. If some automated testing should be added around this, I'd be happy to poke around more and find an appropriate place for it.

[1] - https://github.com/rails/rails/blob/master/activerecord/lib/active_record/tasks/postgresql_database_tasks.rb#L75-L80