Hello. Congrats on Amper. I'm loving it so far! Wh...
# amper
m
Hello. Congrats on Amper. I'm loving it so far! What directory should SQLdelight .SQ files go into so that the SQLdelight plugin sees them? Do you have to use the "gradle-kmp" layout option? TIA!
2
Ahh, nevermind. I've found that I can add the following line to the SQLdelight plugin config and just put a "sqldelight" directory next to the src directory. "srcDirs.setFrom("sqldelight")".
👍 3
i
that is src/sqldelight, right?
m
I put my sqldelight files outside my "src" directory because I don't like the extra directory nesting, but I think it should work inside the "src" directory also.
i
Hmm, I tried that. It can't find it. Oh well!
m
If it helps, here is my "build.gradle.kts":
Copy code
plugins {
    id("app.cash.sqldelight") version "2.0.0"
}

// Configure SQLdelight
sqldelight {
    databases {
        create("Database") {
            srcDirs.setFrom("sqldelight")
        }
    }
}