Describe the bug
Adding migrationsDir
to the plugin's rules config results in an error:
Error: backend/.eslintrc.js:
Configuration for rule "@ts-safeql/check-sql" is invalid:
Value {"migrationsDir":"./lib/migrations","databaseUrl":"postgres://postgres:[email protected]:5432","name":"unstoppable_website_development","operators":["queryRunner.query"]} should NOT have additional properties.
Value {"migrationsDir":"./lib/migrations","databaseUrl":"postgres://postgres:[email protected]:5432","name":"unstoppable_website_development","operators":["queryRunner.query"]} should NOT have additional properties.
Value {"migrationsDir":"./lib/migrations","databaseUrl":"postgres://postgres:[email protected]:5432","name":"unstoppable_website_development","operators":["queryRunner.query"]} should NOT have additional properties.
Value {"migrationsDir":"./lib/migrations","databaseUrl":"postgres://postgres:[email protected]:5432","name":"unstoppable_website_development","operators":["queryRunner.query"]} should NOT have additional properties.
Value {"migrationsDir":"./lib/migrations","databaseUrl":"postgres://postgres:[email protected]:5432","name":"unstoppable_website_development","operators":["queryRunner.query"]} should match some schema in anyOf.
To Reproduce
Steps to reproduce the behavior:
add migrationsDir
to the config.
Expected behavior
A clear and concise description of what you expected to happen.
For the configuration not to error.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Additional context
Add any other context about the problem here.
That's because you can't pass both databaseUrl
and migrationsDir
. The docs aren't very clear about that.
PS
it looks like you want to change your connection configuration to:
{
"migrationsDir": "./lib/migrations",
"databaseName": "unstoppable_website_development_shadow_db",
"queryRunner": "queryRunner",
"operators": ["query"]
}
Closing due to no response from the author.
If you're having hard time trying to configure your settings, then I suggest you to use useConfigFile
with safeql.config.ts
.
For more info, look the release notes of @ts-safeql/[email protected].
Owner Name | ts-safeql |
Repo Name | safeql |
Full Name | ts-safeql/safeql |
Language | TypeScript |
Created Date | 2022-09-08 |
Updated Date | 2023-03-16 |
Star Count | 795 |
Watcher Count | 5 |
Fork Count | 14 |
Issue Count | 7 |
Issue Title | Created Date | Updated Date |
---|