-
Notifications
You must be signed in to change notification settings - Fork 102
/
build.gradle
137 lines (117 loc) · 3.45 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
/*
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
import org.jetbrains.intellij.platform.gradle.TestFrameworkType
plugins {
id "org.jetbrains.intellij.platform" version "2.1.0"
id 'checkstyle'
id 'pmd'
id 'org.jetbrains.changelog' version '2.2.0'
}
repositories {
mavenCentral()
intellijPlatform {
defaultRepositories()
marketplace()
}
}
group 'com.magento.idea'
version '5.4.0'
apply plugin: 'org.jetbrains.intellij.platform'
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'groovy'
apply plugin: 'org.jetbrains.changelog'
def phpPluginVersion = System.getProperty("phpPluginVersion", "242.20224.427")
def ideaVersion = System.getProperty("ideaVersion", "2024.2")
def javaVersion = 17
java {
sourceCompatibility = javaVersion
targetCompatibility = javaVersion
}
intellijPlatform {
version = ideaVersion
projectName = 'com.magento.idea.magento2plugin'
pluginConfiguration {
id = 'com.magento.idea.magento2plugin'
name = 'Magento PhpStorm'
version = '5.4.0'
description = 'This is a PhpStorm IDE plugin for a better Magento 2 development workflow.'
changeNotes = provider { changelog.getLatest().toHTML() } as Provider<? extends String>
}
}
sourceSets {
main {
java.srcDirs 'src'
resources.srcDir 'resources'
}
test {
java.srcDir 'tests'
resources.srcDir 'testData'
}
}
publishPlugin {
token = System.getenv("MAGENTO_PHPSTORM_intellijPublishToken")
if (Boolean.valueOf(System.getenv("MAGENTO_PHPSTORM_isAlpha"))) {
channels = ['alpha']
version = version + "-alpha-" + getDate()
}
}
static def getDate() {
def date = new Date()
def formattedDate = date.format('yyyy-MM-dd-HH-mm')
return formattedDate
}
apply from: "${project.rootDir}/gradle-tasks/staticChecks.gradle"
changelog {
version = "${project.version}"
path = "${project.projectDir}/CHANGELOG.md"
header = provider { "[${project.version}] - ${getDate()}" }
headerParserRegex = ~/(\d+\.)?(\d+\.)?(\*|\d+)/
itemPrefix = "-"
keepUnreleasedSection = true
unreleasedTerm = "[Unreleased]"
groups = ["Added", "Changed", "Deprecated", "Removed", "Fixed", "Security"]
}
idea {
project {
jdkName = javaVersion
languageLevel = javaVersion
}
module {
generatedSourceDirs += file('gen')
}
}
dependencies {
implementation(
"org.junit.jupiter:junit-jupiter:5.8.2",
"com.googlecode.json-simple:json-simple:1.1.1"
)
testRuntimeOnly('org.junit.vintage:junit-vintage-engine:5.9.0')
testRuntimeOnly("org.junit.platform:junit-platform-launcher:1.9.0")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.9.00")
intellijPlatform {
intellijIdeaUltimate '2024.2.3'
plugin("com.jetbrains.php", phpPluginVersion)
plugin("com.intellij.lang.jsgraphql", "242.20224.155")
bundledPlugin "JavaScript"
instrumentationTools()
bundledPlugin 'com.intellij.java'
testFramework TestFrameworkType.Platform.INSTANCE
}
}
test {
useJUnitPlatform {
includeEngines("junit-vintage")
}
dependsOn cleanTest
testLogging.showStandardStreams = true
testLogging {
lifecycle {
events "skipped", "failed", "standard_error", "standard_out"
exceptionFormat "short"
}
}
maxHeapSize = '1G'
}