Skip to content

include non-migration files in the migrations folder #1113

Closed as not planned
Closed as not planned
@sergiycheck

Description

@sergiycheck

Issue Creation Checklist

  • [x ] I understand that my issue will be automatically closed if I don't fill in the requested information
  • I have read the contribution guidelines

Feature Description

I get such error: ERROR: Could not find migration method: up. I have three migration files all with up and down methods. I have .sequelizerc and config.js files. I am running my migration with this command

npx sequelize-cli db:migrate --env development 

The migrations are displayed in postgres and tables are created, but error is thrown at the end.

I've debugged migration script and found out that every file in migration folder must be actual migration and not something else, but I had there a shared file with table names that migration tool thought to be migration. By removing that file bug resolved.

Maybe I we could somehow include non-migration files in migration folder or highlight that info in docs if not already present that every file file in migration folder is must be migration and not something else.

Describe the feature you'd like to see implemented

Describe why you would like this feature to be added to Sequelize

More programmatic access to migrations with .sequelizerc

Is this feature dialect-specific?

  • [ x] No. This feature is relevant to Sequelize as a whole.

Would you be willing to resolve this issue by submitting a Pull Request?

  • Yes, I have the time and I know how to start.
  • Yes, I have the time but I will need guidance.
  • No, I don't have the time, but my company or I are supporting Sequelize through donations on OpenCollective.
  • [x ] No, I don't have the time, and I understand that I will need to wait until someone from the community or maintainers is interested in implementing my feature.

Indicate your interest in the addition of this feature by adding the 👍 reaction. Comments such as "+1" will be removed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions