I am using migrations for my SQLDelight KMM database. They seem to work fine, however, I would like to also verify them as described in the docs. For some reason I do not see the generateSqlDelightSchema task as described there. This is the relevant part of my gradle file:
sqldelight {
databases {
create("ContentHuntDatabase") {
packageName = "com.xamoom.contenthunt.data"
schemaOutputDirectory = file("src/commonMain/sqldelight/com/xamoom/contenthunt/data")
deriveSchemaFromMigrations = true
verifyMigrations = true
generateAsync = true
}
}
}
Any ideas on why I do not see the task?
I am using migrations for my SQLDelight KMM database. They seem to work fine, however, I would like to also verify them as described in the docs. For some reason I do not see the generateSqlDelightSchema task as described there. This is the relevant part of my gradle file:
sqldelight {
databases {
create("ContentHuntDatabase") {
packageName = "com.xamoom.contenthunt.data"
schemaOutputDirectory = file("src/commonMain/sqldelight/com/xamoom/contenthunt/data")
deriveSchemaFromMigrations = true
verifyMigrations = true
generateAsync = true
}
}
}
Any ideas on why I do not see the task?
Share Improve this question asked Nov 19, 2024 at 9:30 Ge ProhaskaGe Prohaska 335 bronze badges1 Answer
Reset to default 0It seems like the SQLDelight documentation is a bit out of date.
Now, SQLDelight generates a task called generate${targetName}${databaseName}Schema
. For example, mine is generateCommonMainAppDatabaseSchema
.
You can see all the tasks available by running this command: gradlew tasks
. In the results, search for "Sqldelight tasks" and you will find all the tasks created by SQLDelight.
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745569727a4633607.html
评论列表(0条)