|
|
@ -299,4 +299,29 @@ if (properties["openrndr.tasks"] == "true") { |
|
|
|
group = " \uD83E\uDD8C OPENRNDR" |
|
|
|
dependsOn("jpackageZip") |
|
|
|
} |
|
|
|
|
|
|
|
task("add IDE file scopes") { |
|
|
|
group = " \uD83E\uDD8C OPENRNDR" |
|
|
|
val scopesFolder = File("${project.projectDir}/.idea/scopes") |
|
|
|
scopesFolder.mkdirs() |
|
|
|
|
|
|
|
val files = listOf( |
|
|
|
"Code" to "file:*.kt||file:*.frag||file:*.vert||file:*.glsl", |
|
|
|
"Text" to "file:*.txt||file:*.md||file:*.xml||file:*.json", |
|
|
|
"Gradle" to "file[*buildSrc*]:*/||file:*gradle.*||file:*.gradle||file:*/gradle-wrapper.properties||file:*.toml", |
|
|
|
"Images" to "file:*.png||file:*.jpg||file:*.dds||file:*.exr" |
|
|
|
) |
|
|
|
files.forEach { (name, pattern) -> |
|
|
|
val file = File(scopesFolder, "__$name.xml") |
|
|
|
if (!file.exists()) { |
|
|
|
file.writeText( |
|
|
|
""" |
|
|
|
<component name="DependencyValidationManager"> |
|
|
|
<scope name=" ★ $name" pattern="$pattern" /> |
|
|
|
</component> |
|
|
|
""".trimIndent() |
|
|
|
) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|