[Feature request] Allow to ignore certain files when running deploy/revert/verify #761
Replies: 3 comments
-
Sqitch expects the files to have the same name as changes but ending in Personally, I like to keep test files in a different directory, it keeps things more compartmentalized. |
Beta Was this translation helpful? Give feedback.
-
Maybe i didn't explain my use case well enough. I am writing DDL and DML in different files in the same project. I was thinking that filtering which files to include in the deploy would allow me to do that. |
Beta Was this translation helpful? Give feedback.
-
In that case, I think you might want two plans. The Separate Plans section of the sqitch-configuration guide describes how, in this case to support two engines, but in your case, you'd have one plan and set of deploy/revert/verify files for DDL and another set for DML, living in separate directories. What you're asking for will never work, because Sqitch uses a merkle chain to ensure that changes are deployed in the proper order. I you omit any from the plan, it won't work at all. |
Beta Was this translation helpful? Give feedback.
-
I am having the following use-case: I have sql files containing both DDL ( tables and functions manily ) and queries. After running the deploy I am running some regression and behavioral tests on the functions on an empty database. The issue i'm facing is that I can't ignore the query files from sqitch.plan and this causes tests to be inconsistent.
Would it make sense to have maybe a flag to allow to ignore a certain pattern of sql files when running deploy/revert/verify. Something like:
sqitch deploy --ignore QUERY* db:pg://user:pass@server:port/database
Beta Was this translation helpful? Give feedback.
All reactions