sheerun / knex-migrate

Modern database migration toolkit for knex.js
MIT License
342 stars 39 forks source link

Migration file pattern dosen't match #31

Closed ta-kiyama closed 6 years ago

ta-kiyama commented 6 years ago

When I use generate command, Some filename doesn't match.

example

  1. use knex-migrate generate [hoge]
  2. YYYYMMDDhhmmss_[hoge].js is created successflly.
  3. use knex-migrate up
  4. But YYYYMMDDhhmmss_[hoge].js doesn't recognize.

reason

https://github.com/sheerun/knex-migrate/blob/master/src/index.js#L115

This regexp accepts only [\w-_]+. So, some filename doesn't match this regexp; e.g. [ and ]

knex.js migrations cli supports any filename, so, I want knex-migrate supports it too.

sheerun commented 6 years ago

merged pr and released as 1.7.0