Skip to content

Commit 5abb5c1

Browse files
authored
version 1.2.16 for PhpStorm 2025.1 (#72)
1 parent 1dbfdcf commit 5abb5c1

36 files changed

Lines changed: 213 additions & 246 deletions

.github/workflows/build.yml

Lines changed: 38 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
name: Build
2-
32
on:
3+
# Trigger the workflow on pushes to only the 'master' branch (this avoids duplicate checks being run e.g., for dependabot pull requests)
44
push:
55
branches: [ master ]
6+
# Trigger the workflow on any pull request
67
pull_request:
78

89
concurrency:
@@ -11,30 +12,32 @@ concurrency:
1112

1213
jobs:
1314

14-
# Prepare environment and build the plugin
15+
# Prepare the environment and build the plugin
1516
build:
1617
name: Build
1718
runs-on: ubuntu-latest
1819
outputs:
1920
version: ${{ steps.properties.outputs.version }}
2021
changelog: ${{ steps.properties.outputs.changelog }}
21-
pluginVerifierHomeDir: ${{ steps.properties.outputs.pluginVerifierHomeDir }}
2222
steps:
2323

24+
# Free GitHub Actions Environment Disk Space
25+
- name: Maximize Build Space
26+
uses: jlumbroso/free-disk-space@v1.3.1
27+
with:
28+
tool-cache: false
29+
large-packages: false
30+
2431
# Check out the current repository
2532
- name: Fetch Sources
2633
uses: actions/checkout@v4
2734

28-
# Validate wrapper
29-
- name: Gradle Wrapper Validation
30-
uses: gradle/actions/wrapper-validation@v3
31-
32-
# Set up Java environment for the next steps
35+
# Set up the Java environment for the next steps
3336
- name: Setup Java
3437
uses: actions/setup-java@v4
3538
with:
3639
distribution: zulu
37-
java-version: 17
40+
java-version: 21
3841

3942
# Setup Gradle
4043
- name: Setup Gradle
@@ -50,8 +53,6 @@ jobs:
5053
CHANGELOG="$(./gradlew getChangelog --unreleased --no-header --console=plain -q)"
5154
5255
echo "version=$VERSION" >> $GITHUB_OUTPUT
53-
echo "pluginVerifierHomeDir=~/.pluginVerifier" >> $GITHUB_OUTPUT
54-
5556
echo "changelog<<EOF" >> $GITHUB_OUTPUT
5657
echo "$CHANGELOG" >> $GITHUB_OUTPUT
5758
echo "EOF" >> $GITHUB_OUTPUT
@@ -60,7 +61,7 @@ jobs:
6061
- name: Build plugin
6162
run: ./gradlew buildPlugin
6263

63-
# Run tests
64+
# Run tests and upload a code coverage report
6465
test:
6566
name: Test (${{ matrix.os }})
6667
needs: [ build ]
@@ -74,20 +75,30 @@ jobs:
7475
- macos-latest
7576
steps:
7677

78+
# Free GitHub Actions Environment Disk Space
79+
- name: Maximize Build Space
80+
uses: jlumbroso/free-disk-space@v1.3.1
81+
if: runner.os == 'Linux'
82+
with:
83+
tool-cache: false
84+
large-packages: false
85+
7786
# Check out the current repository
7887
- name: Fetch Sources
7988
uses: actions/checkout@v4
8089

81-
# Set up Java environment for the next steps
90+
# Set up the Java environment for the next steps
8291
- name: Setup Java
8392
uses: actions/setup-java@v4
8493
with:
8594
distribution: zulu
86-
java-version: 17
95+
java-version: 21
8796

8897
# Setup Gradle
8998
- name: Setup Gradle
9099
uses: gradle/actions/setup-gradle@v4
100+
with:
101+
cache-read-only: true
91102

92103
# Run tests
93104
- name: Run Tests
@@ -98,7 +109,7 @@ jobs:
98109
if: ${{ failure() }}
99110
uses: actions/upload-artifact@v4
100111
with:
101-
name: tests-result
112+
name: tests-result-${{ matrix.os }}
102113
path: ${{ github.workspace }}/build/reports/tests
103114

104115
# Run plugin structure verification along with IntelliJ Plugin Verifier
@@ -108,24 +119,33 @@ jobs:
108119
runs-on: ubuntu-latest
109120
steps:
110121

122+
# Free GitHub Actions Environment Disk Space
123+
- name: Maximize Build Space
124+
uses: jlumbroso/free-disk-space@v1.3.1
125+
with:
126+
tool-cache: false
127+
large-packages: false
128+
111129
# Check out the current repository
112130
- name: Fetch Sources
113131
uses: actions/checkout@v4
114132

115-
# Set up Java environment for the next steps
133+
# Set up the Java environment for the next steps
116134
- name: Setup Java
117135
uses: actions/setup-java@v4
118136
with:
119137
distribution: zulu
120-
java-version: 17
138+
java-version: 21
121139

122140
# Setup Gradle
123141
- name: Setup Gradle
124142
uses: gradle/actions/setup-gradle@v4
143+
with:
144+
cache-read-only: true
125145

126146
# Run Verify Plugin task and IntelliJ Plugin Verifier tool
127147
- name: Run Plugin Verification tasks
128-
run: ./gradlew verifyPlugin -Dplugin.verifier.home.dir=${{ needs.build.outputs.pluginVerifierHomeDir }}
148+
run: ./gradlew verifyPlugin
129149

130150
# Collect Plugin Verifier Result
131151
- name: Collect Plugin Verifier Result

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@
44
build
55
.DS_Store
66
out
7+
.kotlin

.run/Run Plugin.run.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,4 @@
2222
<RunAsTest>false</RunAsTest>
2323
<method v="2" />
2424
</configuration>
25-
</component>
25+
</component>

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## [Unreleased]
44

5+
## [1.2.16] - 04.08.2025
6+
7+
- Adapt code for PhpStorm 2025.1
8+
59
## [1.2.15] - 31.07.2025
610

711
- introduce an intention to add `@kphp-immutable-class` annotation

build.gradle.kts

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,15 @@ plugins {
66
alias(libs.plugins.kotlin) // Kotlin support
77
alias(libs.plugins.intelliJPlatform) // IntelliJ Platform Gradle Plugin
88
alias(libs.plugins.changelog) // Gradle Changelog Plugin
9+
alias(libs.plugins.kover) // Gradle Kover Plugin
910
}
1011

1112
group = providers.gradleProperty("pluginGroup").get()
1213
version = providers.gradleProperty("pluginVersion").get()
1314

1415
// Set the JVM language level used to build the project.
1516
kotlin {
16-
jvmToolchain(17)
17+
jvmToolchain(21)
1718
}
1819

1920
// Configure project's dependencies
@@ -29,6 +30,7 @@ repositories {
2930
// Dependencies are managed with Gradle version catalog - read more: https://docs.gradle.org/current/userguide/platforms.html#sub:version-catalog
3031
dependencies {
3132
testImplementation(libs.junit)
33+
testImplementation(libs.opentest4j)
3234

3335
// IntelliJ Platform Gradle Plugin Dependencies Extension - read more: https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin-dependencies-extension.html
3436
intellijPlatform {
@@ -40,16 +42,14 @@ dependencies {
4042
// Plugin Dependencies. Uses `platformPlugins` property from the gradle.properties file for plugin from JetBrains Marketplace.
4143
plugins(providers.gradleProperty("platformPlugins").map { it.split(',') })
4244

43-
instrumentationTools()
44-
pluginVerifier()
45-
zipSigner()
4645
testFramework(TestFrameworkType.Platform)
4746
}
4847
}
4948

5049
// Configure IntelliJ Platform Gradle Plugin - read more: https://plugins.jetbrains.com/docs/intellij/tools-intellij-platform-gradle-plugin-extension.html
5150
intellijPlatform {
5251
pluginConfiguration {
52+
name = providers.gradleProperty("pluginName")
5353
version = providers.gradleProperty("pluginVersion")
5454

5555
val changelog = project.changelog // local variable for configuration cache compatibility
@@ -86,6 +86,17 @@ changelog {
8686
repositoryUrl = providers.gradleProperty("pluginRepositoryUrl")
8787
}
8888

89+
// Configure Gradle Kover Plugin - read more: https://github.com/Kotlin/kotlinx-kover#configuration
90+
kover {
91+
reports {
92+
total {
93+
xml {
94+
onCheck = true
95+
}
96+
}
97+
}
98+
}
99+
89100
tasks {
90101
wrapper {
91102
gradleVersion = providers.gradleProperty("gradleVersion").get()

gradle.properties

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,24 @@ pluginGroup = com.vk
44
pluginName = kphpstorm
55
pluginRepositoryUrl = https://github.com/VKCOM/kphpstorm
66
# SemVer format -> https://semver.org
7-
pluginVersion = 1.2.15
7+
pluginVersion = 1.2.16
88

99
# Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
10-
pluginSinceBuild = 243
11-
pluginUntilBuild = 243.*
10+
pluginSinceBuild = 251
11+
pluginUntilBuild = 251.*
1212

1313
# IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html#configuration-intellij-extension
14-
platformType = IU
15-
platformVersion = 2024.3
14+
platformType = PS
15+
platformVersion = 2025.1
1616

1717
# Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html
1818
# Example: platformPlugins = com.jetbrains.php:203.4449.22, org.intellij.scala:2023.3.27@EAP
19-
platformPlugins = com.jetbrains.php:243.21565.211
19+
platformPlugins =
2020
# Example: platformBundledPlugins = com.intellij.java
21-
platformBundledPlugins = com.intellij.java
21+
platformBundledPlugins = com.jetbrains.php
2222

2323
# Gradle Releases -> https://github.com/gradle/gradle/releases
24-
gradleVersion = 8.10.2
24+
gradleVersion = 8.14.3
2525

2626
# Opt-out flag for bundling Kotlin standard library -> https://jb.gg/intellij-platform-kotlin-stdlib
2727
kotlin.stdlib.default.dependency = false

gradle/libs.versions.toml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,20 @@
11
[versions]
22
# libraries
33
junit = "4.13.2"
4+
opentest4j = "1.3.0"
45

56
# plugins
6-
changelog = "2.2.1"
7-
intelliJPlatform = "2.0.1" # TODO: update this in next update: https://youtrack.jetbrains.com/issue/MP-7019
8-
kotlin = "1.9.25"
7+
changelog = "2.3.0"
8+
intelliJPlatform = "2.7.0"
9+
kotlin = "2.2.0"
10+
kover = "0.9.1"
911

1012
[libraries]
1113
junit = { group = "junit", name = "junit", version.ref = "junit" }
14+
opentest4j = { group = "org.opentest4j", name = "opentest4j", version.ref = "opentest4j" }
1215

1316
[plugins]
1417
changelog = { id = "org.jetbrains.changelog", version.ref = "changelog" }
1518
intelliJPlatform = { id = "org.jetbrains.intellij.platform", version.ref = "intelliJPlatform" }
1619
kotlin = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
20+
kover = { id = "org.jetbrains.kotlinx.kover", version.ref = "kover" }

gradle/wrapper/gradle-wrapper.jar

181 Bytes
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

gradlew

Lines changed: 4 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)