33 * See COPYING.txt for license details.
44 */
55
6- import groovy.json.JsonSlurper
76import org.jetbrains.changelog.Changelog
87import org.jetbrains.changelog.markdownToHTML
98import org.jetbrains.intellij.platform.gradle.TestFrameworkType
109
1110plugins {
1211 id(" java" )
13- id(" checkstyle" )
14- id(" pmd" )
1512 alias(libs.plugins.kotlin)
1613 alias(libs.plugins.intelliJPlatform)
1714 alias(libs.plugins.changelog)
@@ -51,12 +48,9 @@ dependencies {
5148
5249 bundledPlugins(providers.gradleProperty(" platformBundledPlugins" ).map { it.split(' ,' ) })
5350 plugins(providers.gradleProperty(" platformPlugins" ).map { it.split(' ,' ) })
54- plugin(" com.intellij.lang.jsgraphql" , " 243.21565.122" )
5551 pluginVerifier()
5652 zipSigner()
5753 testFramework(TestFrameworkType .Platform )
58-
59- phpstorm(" 2024.3" )
6054 }
6155}
6256
@@ -146,22 +140,14 @@ tasks {
146140 }
147141 }
148142
143+ // Workaround for kernel-related crashes in tests (Fleet/Platform Kernel background tasks)
144+ systemProperty(" intellij.platform.kernel.disable" , " true" )
145+ systemProperty(" ide.fleet.launch" , " false" )
146+
149147 useJUnitPlatform()
150148 }
151149
152- checkstyle {
153- toolVersion = " 8.31"
154- isIgnoreFailures = false
155- maxWarnings = 0
156- configFile = rootProject.file(" ${rootDir} /gradle-tasks/checkstyle/checkstyle.xml" )
157- }
158150
159- pmd {
160- toolVersion = " 6.21.0"
161- isConsoleOutput = true
162- ruleSetFiles = files(" ${rootDir} /gradle-tasks/pmd/ruleset.xml" )
163- ruleSets = listOf ()
164- }
165151}
166152
167153intellijPlatformTesting {
@@ -174,6 +160,8 @@ intellijPlatformTesting {
174160 " -Dide.mac.message.dialogs.as.sheets=false" ,
175161 " -Djb.privacy.policy.text=<!--999.999-->" ,
176162 " -Djb.consents.confirmation.enabled=false" ,
163+ " -Deap.require.license=true" ,
164+ " -Dide.show.tips.on.startup.default.value=false"
177165 )
178166 }
179167 }
@@ -185,68 +173,12 @@ intellijPlatformTesting {
185173 }
186174}
187175
188- // Configure Checkstyle tasks
189- tasks.withType(Checkstyle ::class ).configureEach {
190- // Specify all files that should be checked
191- classpath = files()
192- setSource(" ${project.rootDir} " )
193- }
194-
195- // Execute Checkstyle on all files
196- tasks.register<Checkstyle >(" checkstyle" ) {
197- // Task-specific configuration can go here if necessary
198- }
199-
200- // Execute Checkstyle on all modified files
201- tasks.register<Checkstyle >(" checkstyleCI" ) {
202- val changedFiles = getChangedFiles()
203- include(changedFiles)
204- }
205-
206- // Configure PMD tasks
207- tasks.withType(Pmd ::class ).configureEach {
208- // Specify all files that should be checked
209- classpath = files()
210- setSource(" ${project.rootDir} " )
211- }
212-
213- // Execute PMD on all files
214- tasks.register<Pmd >(" pmd" ) {
215- // Task-specific configuration can go here if necessary
216- }
217-
218- // Execute PMD on all modified files
219- tasks.register<Pmd >(" pmdCI" ) {
220- val changedFiles = getChangedFiles()
221- include(changedFiles)
222- }
223176
224- /* *
225- * Get all files that are changed but not deleted nor renamed.
226- * Compares to master or the specified target branch.
227- *
228- * @return list of all changed files
229- */
230- fun getChangedFiles (): List <String > {
231- val modifiedFilesJson = System .getenv(" MODIFIED_FILES" )
232- val files = mutableListOf<String >()
233177
234- if (modifiedFilesJson == null ) {
235- return files
236- }
237178
238- println (" Modified Files: $modifiedFilesJson " )
239179
240- // Parse the JSON string into a list of files
241- val modifiedFiles = JsonSlurper ().parseText(modifiedFilesJson) as List <* >
242180
243- modifiedFiles.forEach {
244- files.add(it.toString())
245- }
246181
247- // Return the list of touched files
248- return files
249- }
250182
251183kover {
252184 currentProject {
0 commit comments