feat(combat): add 232.* support
This commit is contained in:
parent
1f7b796973
commit
e34d23fe06
213
.github/workflows/build.yml
vendored
213
.github/workflows/build.yml
vendored
@ -1,12 +1,12 @@
|
||||
# GitHub Actions Workflow created for testing and preparing the plugin release in following steps:
|
||||
# - validate Gradle Wrapper,
|
||||
# - run 'test' and 'verifyPlugin' tasks,
|
||||
# - run Qodana inspections,
|
||||
# - run 'buildPlugin' task and prepare artifact for the further tests,
|
||||
# - run 'runPluginVerifier' task,
|
||||
# - create a draft release.
|
||||
# GitHub Actions Workflow is created for testing and preparing the plugin release in the following steps:
|
||||
# - Validate Gradle Wrapper.
|
||||
# - Run 'test' and 'verifyPlugin' tasks.
|
||||
# - Run Qodana inspections.
|
||||
# - Run the 'buildPlugin' task and prepare artifact for further tests.
|
||||
# - Run the 'runPluginVerifier' task.
|
||||
# - Create a draft release.
|
||||
#
|
||||
# Workflow is triggered on push and pull_request events.
|
||||
# The workflow is triggered on push and pull_request events.
|
||||
#
|
||||
# GitHub Actions reference: https://help.github.com/en/actions
|
||||
#
|
||||
@ -14,7 +14,7 @@
|
||||
|
||||
name: Build
|
||||
on:
|
||||
# Trigger the workflow on pushes to only the 'main' branch (this avoids duplicate checks being run e.g. for dependabot pull requests)
|
||||
# Trigger the workflow on pushes to only the 'main' branch (this avoids duplicate checks being run e.g., for dependabot pull requests)
|
||||
push:
|
||||
branches: [ main ]
|
||||
# Trigger the workflow on any pull request
|
||||
@ -22,38 +22,36 @@ on:
|
||||
|
||||
jobs:
|
||||
|
||||
# Run Gradle Wrapper Validation Action to verify the wrapper's checksum
|
||||
# Run verifyPlugin, IntelliJ Plugin Verifier, and test Gradle tasks
|
||||
# Build plugin and provide the artifact for the next workflow jobs
|
||||
# Prepare environment and build the plugin
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
version: ${{ steps.properties.outputs.version }}
|
||||
changelog: ${{ steps.properties.outputs.changelog }}
|
||||
pluginVerifierHomeDir: ${{ steps.properties.outputs.pluginVerifierHomeDir }}
|
||||
steps:
|
||||
|
||||
# Free GitHub Actions Environment Disk Space
|
||||
- name: Maximize Build Space
|
||||
run: |
|
||||
sudo rm -rf /usr/share/dotnet
|
||||
sudo rm -rf /usr/local/lib/android
|
||||
sudo rm -rf /opt/ghc
|
||||
|
||||
# Check out current repository
|
||||
- name: Fetch Sources
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Validate wrapper
|
||||
- name: Gradle Wrapper Validation
|
||||
uses: gradle/wrapper-validation-action@v1.0.5
|
||||
uses: gradle/wrapper-validation-action@v1.1.0
|
||||
|
||||
# Setup Java 11 environment for the next steps
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 11
|
||||
java-version: 17
|
||||
|
||||
# Setup Gradle
|
||||
- name: Setup Gradle
|
||||
uses: gradle/gradle-build-action@v2
|
||||
with:
|
||||
gradle-home-cache-cleanup: true
|
||||
|
||||
# Set environment variables
|
||||
- name: Export Properties
|
||||
@ -62,19 +60,63 @@ jobs:
|
||||
run: |
|
||||
PROPERTIES="$(./gradlew properties --console=plain -q)"
|
||||
VERSION="$(echo "$PROPERTIES" | grep "^version:" | cut -f2- -d ' ')"
|
||||
NAME="$(echo "$PROPERTIES" | grep "^pluginName:" | cut -f2- -d ' ')"
|
||||
CHANGELOG="$(./gradlew getChangelog --unreleased --no-header --console=plain -q)"
|
||||
CHANGELOG="${CHANGELOG//'%'/'%25'}"
|
||||
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
|
||||
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
|
||||
|
||||
echo "::set-output name=version::$VERSION"
|
||||
echo "::set-output name=name::$NAME"
|
||||
echo "::set-output name=changelog::$CHANGELOG"
|
||||
echo "::set-output name=pluginVerifierHomeDir::~/.pluginVerifier"
|
||||
echo "version=$VERSION" >> $GITHUB_OUTPUT
|
||||
echo "pluginVerifierHomeDir=~/.pluginVerifier" >> $GITHUB_OUTPUT
|
||||
|
||||
echo "changelog<<EOF" >> $GITHUB_OUTPUT
|
||||
echo "$CHANGELOG" >> $GITHUB_OUTPUT
|
||||
echo "EOF" >> $GITHUB_OUTPUT
|
||||
|
||||
./gradlew listProductsReleases # prepare list of IDEs for Plugin Verifier
|
||||
|
||||
# Build plugin
|
||||
- name: Build plugin
|
||||
run: ./gradlew buildPlugin
|
||||
|
||||
# Prepare plugin archive content for creating artifact
|
||||
- name: Prepare Plugin Artifact
|
||||
id: artifact
|
||||
shell: bash
|
||||
run: |
|
||||
cd ${{ github.workspace }}/build/distributions
|
||||
FILENAME=`ls *.zip`
|
||||
unzip "$FILENAME" -d content
|
||||
|
||||
echo "filename=${FILENAME:0:-4}" >> $GITHUB_OUTPUT
|
||||
|
||||
# Store already-built plugin as an artifact for downloading
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: ${{ steps.artifact.outputs.filename }}
|
||||
path: ./build/distributions/content/*/*
|
||||
|
||||
# Run tests and upload a code coverage report
|
||||
test:
|
||||
name: Test
|
||||
needs: [ build ]
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
# Check out current repository
|
||||
- name: Fetch Sources
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 17
|
||||
|
||||
# Setup Gradle
|
||||
- name: Setup Gradle
|
||||
uses: gradle/gradle-build-action@v2
|
||||
with:
|
||||
gradle-home-cache-cleanup: true
|
||||
|
||||
# Run tests
|
||||
- name: Run Tests
|
||||
run: ./gradlew check
|
||||
@ -87,22 +129,88 @@ jobs:
|
||||
name: tests-result
|
||||
path: ${{ github.workspace }}/build/reports/tests
|
||||
|
||||
# Upload Kover report to CodeCov
|
||||
# Upload the Kover report to CodeCov
|
||||
- name: Upload Code Coverage Report
|
||||
uses: codecov/codecov-action@v3
|
||||
with:
|
||||
files: ${{ github.workspace }}/build/reports/kover/xml/report.xml
|
||||
files: ${{ github.workspace }}/build/reports/kover/report.xml
|
||||
|
||||
# Run Qodana inspections and provide report
|
||||
inspectCode:
|
||||
name: Inspect code
|
||||
needs: [ build ]
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: write
|
||||
checks: write
|
||||
pull-requests: write
|
||||
steps:
|
||||
|
||||
# Free GitHub Actions Environment Disk Space
|
||||
- name: Maximize Build Space
|
||||
uses: jlumbroso/free-disk-space@main
|
||||
with:
|
||||
tool-cache: false
|
||||
large-packages: false
|
||||
|
||||
# Check out current repository
|
||||
- name: Fetch Sources
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 17
|
||||
|
||||
# Run Qodana inspections
|
||||
- name: Qodana - Code Inspection
|
||||
uses: JetBrains/qodana-action@v2023.2.1
|
||||
with:
|
||||
cache-default-branch-only: true
|
||||
|
||||
# Run plugin structure verification along with IntelliJ Plugin Verifier
|
||||
verify:
|
||||
name: Verify plugin
|
||||
needs: [ build ]
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
# Free GitHub Actions Environment Disk Space
|
||||
- name: Maximize Build Space
|
||||
uses: jlumbroso/free-disk-space@main
|
||||
with:
|
||||
tool-cache: false
|
||||
large-packages: false
|
||||
|
||||
# Check out current repository
|
||||
- name: Fetch Sources
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 17
|
||||
|
||||
# Setup Gradle
|
||||
- name: Setup Gradle
|
||||
uses: gradle/gradle-build-action@v2
|
||||
with:
|
||||
gradle-home-cache-cleanup: true
|
||||
|
||||
# Cache Plugin Verifier IDEs
|
||||
- name: Setup Plugin Verifier IDEs Cache
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ${{ steps.properties.outputs.pluginVerifierHomeDir }}/ides
|
||||
path: ${{ needs.build.outputs.pluginVerifierHomeDir }}/ides
|
||||
key: plugin-verifier-${{ hashFiles('build/listProductsReleases.txt') }}
|
||||
|
||||
# Run Verify Plugin task and IntelliJ Plugin Verifier tool
|
||||
- name: Run Plugin Verification tasks
|
||||
run: ./gradlew runPluginVerifier -Pplugin.verifier.home.dir=${{ steps.properties.outputs.pluginVerifierHomeDir }}
|
||||
run: ./gradlew runPluginVerifier -Dplugin.verifier.home.dir=${{ needs.build.outputs.pluginVerifierHomeDir }}
|
||||
|
||||
# Collect Plugin Verifier Result
|
||||
- name: Collect Plugin Verifier Result
|
||||
@ -112,34 +220,12 @@ jobs:
|
||||
name: pluginVerifier-result
|
||||
path: ${{ github.workspace }}/build/reports/pluginVerifier
|
||||
|
||||
# Run Qodana inspections
|
||||
- name: Qodana - Code Inspection
|
||||
uses: JetBrains/qodana-action@v2022.2.3
|
||||
|
||||
# Prepare plugin archive content for creating artifact
|
||||
- name: Prepare Plugin Artifact
|
||||
id: artifact
|
||||
shell: bash
|
||||
run: |
|
||||
cd ${{ github.workspace }}/build/distributions
|
||||
FILENAME=`ls *.zip`
|
||||
unzip "$FILENAME" -d content
|
||||
|
||||
echo "::set-output name=filename::${FILENAME:0:-4}"
|
||||
|
||||
# Store already-built plugin as an artifact for downloading
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: ${{ steps.artifact.outputs.filename }}
|
||||
path: ./build/distributions/content/*/*
|
||||
|
||||
# Prepare a draft release for GitHub Releases page for the manual verification
|
||||
# If accepted and published, release workflow would be triggered
|
||||
releaseDraft:
|
||||
name: Release Draft
|
||||
name: Release draft
|
||||
if: github.event_name != 'pull_request'
|
||||
needs: build
|
||||
needs: [ build, test, inspectCode, verify ]
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: write
|
||||
@ -149,7 +235,14 @@ jobs:
|
||||
- name: Fetch Sources
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Remove old release drafts by using the curl request for the available releases with draft flag
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 17
|
||||
|
||||
# Remove old release drafts by using the curl request for the available releases with a draft flag
|
||||
- name: Remove Old Release Drafts
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
@ -158,7 +251,7 @@ jobs:
|
||||
--jq '.[] | select(.draft == true) | .id' \
|
||||
| xargs -I '{}' gh api -X DELETE repos/{owner}/{repo}/releases/{}
|
||||
|
||||
# Create new release draft - which is not publicly visible and requires manual acceptance
|
||||
# Create a new release draft which is not publicly visible and requires manual acceptance
|
||||
- name: Create Release Draft
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
30
.github/workflows/release.yml
vendored
30
.github/workflows/release.yml
vendored
@ -1,5 +1,6 @@
|
||||
# GitHub Actions Workflow created for handling the release process based on the draft release prepared
|
||||
# with the Build workflow. Running the publishPlugin task requires the PUBLISH_TOKEN secret provided.
|
||||
# GitHub Actions Workflow created for handling the release process based on the draft release prepared with the Build workflow.
|
||||
# Running the publishPlugin task requires all following secrets to be provided: PUBLISH_TOKEN, PRIVATE_KEY, PRIVATE_KEY_PASSWORD, CERTIFICATE_CHAIN.
|
||||
# See https://plugins.jetbrains.com/docs/intellij/plugin-signing.html for more information.
|
||||
|
||||
name: Release
|
||||
on:
|
||||
@ -8,7 +9,7 @@ on:
|
||||
|
||||
jobs:
|
||||
|
||||
# Prepare and publish the plugin to the Marketplace repository
|
||||
# Prepare and publish the plugin to JetBrains Marketplace repository
|
||||
release:
|
||||
name: Publish Plugin
|
||||
runs-on: ubuntu-latest
|
||||
@ -23,12 +24,18 @@ jobs:
|
||||
with:
|
||||
ref: ${{ github.event.release.tag_name }}
|
||||
|
||||
# Setup Java 11 environment for the next steps
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 11
|
||||
java-version: 17
|
||||
|
||||
# Setup Gradle
|
||||
- name: Setup Gradle
|
||||
uses: gradle/gradle-build-action@v2
|
||||
with:
|
||||
gradle-home-cache-cleanup: true
|
||||
|
||||
# Set environment variables
|
||||
- name: Export Properties
|
||||
@ -40,11 +47,9 @@ jobs:
|
||||
EOM
|
||||
)"
|
||||
|
||||
CHANGELOG="${CHANGELOG//'%'/'%25'}"
|
||||
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
|
||||
CHANGELOG="${CHANGELOG//$'\r'/'%0D'}"
|
||||
|
||||
echo "::set-output name=changelog::$CHANGELOG"
|
||||
echo "changelog<<EOF" >> $GITHUB_OUTPUT
|
||||
echo "$CHANGELOG" >> $GITHUB_OUTPUT
|
||||
echo "EOF" >> $GITHUB_OUTPUT
|
||||
|
||||
# Update Unreleased section with the current release note
|
||||
- name: Patch Changelog
|
||||
@ -54,7 +59,7 @@ jobs:
|
||||
run: |
|
||||
./gradlew patchChangelog --release-note="$CHANGELOG"
|
||||
|
||||
# Publish the plugin to the Marketplace
|
||||
# Publish the plugin to JetBrains Marketplace
|
||||
- name: Publish Plugin
|
||||
env:
|
||||
PUBLISH_TOKEN: ${{ secrets.PUBLISH_TOKEN }}
|
||||
@ -69,7 +74,7 @@ jobs:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: gh release upload ${{ github.event.release.tag_name }} ./build/distributions/*
|
||||
|
||||
# Create pull request
|
||||
# Create a pull request
|
||||
- name: Create Pull Request
|
||||
if: ${{ steps.properties.outputs.changelog != '' }}
|
||||
env:
|
||||
@ -88,6 +93,7 @@ jobs:
|
||||
|
||||
gh label create "$LABEL" \
|
||||
--description "Pull requests with release changelog update" \
|
||||
--force \
|
||||
|| true
|
||||
|
||||
gh pr create \
|
||||
|
18
.github/workflows/run-ui-tests.yml
vendored
18
.github/workflows/run-ui-tests.yml
vendored
@ -1,9 +1,9 @@
|
||||
# GitHub Actions Workflow for launching UI tests on Linux, Windows, and Mac in the following steps:
|
||||
# - prepare and launch IDE with your plugin and robot-server plugin, which is needed to interact with UI
|
||||
# - wait for IDE to start
|
||||
# - run UI tests with separate Gradle task
|
||||
# - Prepare and launch IDE with your plugin and robot-server plugin, which is needed to interact with the UI.
|
||||
# - Wait for IDE to start.
|
||||
# - Run UI tests with a separate Gradle task.
|
||||
#
|
||||
# Please check https://github.com/JetBrains/intellij-ui-test-robot for information about UI tests with IntelliJ Platform
|
||||
# Please check https://github.com/JetBrains/intellij-ui-test-robot for information about UI tests with IntelliJ Platform.
|
||||
#
|
||||
# Workflow is triggered manually.
|
||||
|
||||
@ -35,12 +35,18 @@ jobs:
|
||||
- name: Fetch Sources
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Setup Java 11 environment for the next steps
|
||||
# Set up Java environment for the next steps
|
||||
- name: Setup Java
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
distribution: zulu
|
||||
java-version: 11
|
||||
java-version: 17
|
||||
|
||||
# Setup Gradle
|
||||
- name: Setup Gradle
|
||||
uses: gradle/gradle-build-action@v2
|
||||
with:
|
||||
gradle-home-cache-cleanup: true
|
||||
|
||||
# Run IDEA prepared for UI testing
|
||||
- name: Run IDE
|
||||
|
@ -5,18 +5,21 @@
|
||||
<option name="executionName" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="externalSystemIdString" value="GRADLE" />
|
||||
<option name="scriptParameters" value="runIdeForUiTests" />
|
||||
<option name="scriptParameters" value="" />
|
||||
<option name="taskDescriptions">
|
||||
<list />
|
||||
</option>
|
||||
<option name="taskNames">
|
||||
<list />
|
||||
<list>
|
||||
<option value="runIdeForUiTests" />
|
||||
</list>
|
||||
</option>
|
||||
<option name="vmOptions" />
|
||||
</ExternalSystemSettings>
|
||||
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
|
||||
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
|
||||
<DebugAllEnabled>false</DebugAllEnabled>
|
||||
<RunAsTest>false</RunAsTest>
|
||||
<method v="2" />
|
||||
</configuration>
|
||||
</component>
|
@ -9,18 +9,22 @@
|
||||
<option name="executionName" />
|
||||
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
||||
<option name="externalSystemIdString" value="GRADLE" />
|
||||
<option name="scriptParameters" value="cleanInspections runInspections" />
|
||||
<option name="scriptParameters" value="" />
|
||||
<option name="taskDescriptions">
|
||||
<list />
|
||||
</option>
|
||||
<option name="taskNames">
|
||||
<list />
|
||||
<list>
|
||||
<option value="cleanInspections" />
|
||||
<option value="runInspections" />
|
||||
</list>
|
||||
</option>
|
||||
<option name="vmOptions" />
|
||||
</ExternalSystemSettings>
|
||||
<ExternalSystemDebugServerProcess>true</ExternalSystemDebugServerProcess>
|
||||
<ExternalSystemReattachDebugProcess>true</ExternalSystemReattachDebugProcess>
|
||||
<DebugAllEnabled>false</DebugAllEnabled>
|
||||
<RunAsTest>false</RunAsTest>
|
||||
<method v="2" />
|
||||
</configuration>
|
||||
</component>
|
@ -11,7 +11,7 @@
|
||||
</option>
|
||||
<option name="taskNames">
|
||||
<list>
|
||||
<option value="test" />
|
||||
<option value="check" />
|
||||
</list>
|
||||
</option>
|
||||
<option name="vmOptions" value="" />
|
@ -4,6 +4,9 @@
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
### Added
|
||||
- Support for all 2023.2 builds (232.*)
|
||||
|
||||
## [4.4.1] - 2023-02-19
|
||||
|
||||
### Changed
|
||||
|
@ -1,101 +1,105 @@
|
||||
import org.jetbrains.changelog.Changelog
|
||||
import org.jetbrains.changelog.markdownToHTML
|
||||
|
||||
fun properties(key: String) = project.findProperty(key).toString()
|
||||
fun properties(key: String) = providers.gradleProperty(key)
|
||||
fun environment(key: String) = providers.environmentVariable(key)
|
||||
|
||||
plugins {
|
||||
// Java support
|
||||
id("java")
|
||||
// Kotlin support
|
||||
id("org.jetbrains.kotlin.jvm") version "1.7.21"
|
||||
// Gradle IntelliJ Plugin
|
||||
id("org.jetbrains.intellij") version "1.13.0"
|
||||
// Gradle Changelog Plugin
|
||||
id("org.jetbrains.changelog") version "2.0.0"
|
||||
// Gradle Qodana Plugin
|
||||
id("org.jetbrains.qodana") version "0.1.13"
|
||||
// Gradle Kover Plugin
|
||||
id("org.jetbrains.kotlinx.kover") version "0.6.1"
|
||||
id("java") // Java support
|
||||
alias(libs.plugins.kotlin) // Kotlin support
|
||||
alias(libs.plugins.gradleIntelliJPlugin) // Gradle IntelliJ Plugin
|
||||
alias(libs.plugins.changelog) // Gradle Changelog Plugin
|
||||
alias(libs.plugins.qodana) // Gradle Qodana Plugin
|
||||
alias(libs.plugins.kover) // Gradle Kover Plugin
|
||||
}
|
||||
|
||||
group = properties("pluginGroup")
|
||||
version = properties("pluginVersion")
|
||||
group = properties("pluginGroup").get()
|
||||
version = properties("pluginVersion").get()
|
||||
|
||||
// Configure project's dependencies
|
||||
repositories {
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
// Dependencies are managed with Gradle version catalog - read more: https://docs.gradle.org/current/userguide/platforms.html#sub:version-catalog
|
||||
dependencies {
|
||||
implementation("de.marhali:json5-java:2.0.0")
|
||||
// implementation(libs.annotations)
|
||||
implementation(libs.json5.java)
|
||||
}
|
||||
|
||||
// Set the JVM language level used to build project. Use Java 11 for 2020.3+, and Java 17 for 2022.2+.
|
||||
// Set the JVM language level used to build the project. Use Java 11 for 2020.3+, and Java 17 for 2022.2+.
|
||||
kotlin {
|
||||
jvmToolchain(17)
|
||||
}
|
||||
|
||||
// Configure Gradle IntelliJ Plugin - read more: https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html
|
||||
intellij {
|
||||
pluginName.set(properties("pluginName"))
|
||||
version.set(properties("platformVersion"))
|
||||
type.set(properties("platformType"))
|
||||
pluginName = properties("pluginName")
|
||||
version = properties("platformVersion")
|
||||
type = properties("platformType")
|
||||
|
||||
// Plugin Dependencies. Uses `platformPlugins` property from the gradle.properties file.
|
||||
plugins.set(properties("platformPlugins").split(',').map(String::trim).filter(String::isNotEmpty))
|
||||
plugins = properties("platformPlugins").map { it.split(',').map(String::trim).filter(String::isNotEmpty) }
|
||||
}
|
||||
|
||||
// Configure Gradle Changelog Plugin - read more: https://github.com/JetBrains/gradle-changelog-plugin
|
||||
changelog {
|
||||
groups.set(emptyList())
|
||||
repositoryUrl.set(properties("pluginRepositoryUrl"))
|
||||
groups.empty()
|
||||
repositoryUrl = properties("pluginRepositoryUrl")
|
||||
}
|
||||
|
||||
// Configure Gradle Qodana Plugin - read more: https://github.com/JetBrains/gradle-qodana-plugin
|
||||
qodana {
|
||||
cachePath.set(file(".qodana").canonicalPath)
|
||||
reportPath.set(file("build/reports/inspections").canonicalPath)
|
||||
saveReport.set(true)
|
||||
showReport.set(System.getenv("QODANA_SHOW_REPORT")?.toBoolean() ?: false)
|
||||
cachePath = provider { file(".qodana").canonicalPath }
|
||||
reportPath = provider { file("build/reports/inspections").canonicalPath }
|
||||
saveReport = true
|
||||
showReport = environment("QODANA_SHOW_REPORT").map { it.toBoolean() }.getOrElse(false)
|
||||
}
|
||||
|
||||
// Configure Gradle Kover Plugin - read more: https://github.com/Kotlin/kotlinx-kover#configuration
|
||||
kover.xmlReport {
|
||||
onCheck.set(true)
|
||||
koverReport {
|
||||
defaults {
|
||||
xml {
|
||||
onCheck = true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tasks {
|
||||
wrapper {
|
||||
gradleVersion = properties("gradleVersion")
|
||||
gradleVersion = properties("gradleVersion").get()
|
||||
}
|
||||
|
||||
patchPluginXml {
|
||||
version.set(properties("pluginVersion"))
|
||||
sinceBuild.set(properties("pluginSinceBuild"))
|
||||
untilBuild.set(properties("pluginUntilBuild"))
|
||||
version = properties("pluginVersion")
|
||||
sinceBuild = properties("pluginSinceBuild")
|
||||
untilBuild = properties("pluginUntilBuild")
|
||||
|
||||
// Extract the <!-- Plugin description --> section from README.md and provide for the plugin's manifest
|
||||
pluginDescription.set(
|
||||
file("README.md").readText().lines().run {
|
||||
pluginDescription = providers.fileContents(layout.projectDirectory.file("README.md")).asText.map {
|
||||
val start = "<!-- Plugin description -->"
|
||||
val end = "<!-- Plugin description end -->"
|
||||
|
||||
with (it.lines()) {
|
||||
if (!containsAll(listOf(start, end))) {
|
||||
throw GradleException("Plugin description section not found in README.md:\n$start ... $end")
|
||||
}
|
||||
subList(indexOf(start) + 1, indexOf(end))
|
||||
}.joinToString("\n").let { markdownToHTML(it) }
|
||||
)
|
||||
subList(indexOf(start) + 1, indexOf(end)).joinToString("\n").let(::markdownToHTML)
|
||||
}
|
||||
}
|
||||
|
||||
val changelog = project.changelog // local variable for configuration cache compatibility
|
||||
// Get the latest available change notes from the changelog file
|
||||
changeNotes.set(provider {
|
||||
changeNotes = properties("pluginVersion").map { pluginVersion ->
|
||||
with(changelog) {
|
||||
renderItem(
|
||||
getOrNull(properties("pluginVersion")) ?: getLatest(),
|
||||
(getOrNull(pluginVersion) ?: getUnreleased())
|
||||
.withHeader(false)
|
||||
.withEmptySections(false),
|
||||
Changelog.OutputType.HTML,
|
||||
)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
// Configure UI tests plugin
|
||||
@ -108,17 +112,17 @@ tasks {
|
||||
}
|
||||
|
||||
signPlugin {
|
||||
certificateChain.set(System.getenv("CERTIFICATE_CHAIN"))
|
||||
privateKey.set(System.getenv("PRIVATE_KEY"))
|
||||
password.set(System.getenv("PRIVATE_KEY_PASSWORD"))
|
||||
certificateChain = environment("CERTIFICATE_CHAIN")
|
||||
privateKey = environment("PRIVATE_KEY")
|
||||
password = environment("PRIVATE_KEY_PASSWORD")
|
||||
}
|
||||
|
||||
publishPlugin {
|
||||
dependsOn("patchChangelog")
|
||||
token.set(System.getenv("PUBLISH_TOKEN"))
|
||||
// pluginVersion is based on the SemVer (https://semver.org) and supports pre-release labels, like 2.1.7-alpha.3
|
||||
token = environment("PUBLISH_TOKEN")
|
||||
// The pluginVersion is based on the SemVer (https://semver.org) and supports pre-release labels, like 2.1.7-alpha.3
|
||||
// Specify pre-release label to publish the plugin in a custom Release Channel automatically. Read more:
|
||||
// https://plugins.jetbrains.com/docs/intellij/deployment.html#specifying-a-release-channel
|
||||
channels.set(listOf(properties("pluginVersion").split('-').getOrElse(1) { "default" }.split('.').first()))
|
||||
channels = properties("pluginVersion").map { listOf(it.split('-').getOrElse(1) { "default" }.split('.').first()) }
|
||||
}
|
||||
}
|
@ -2,28 +2,33 @@
|
||||
|
||||
pluginGroup = de.marhali.easyi18n
|
||||
pluginName = easy-i18n
|
||||
pluginRepositoryUrl = https://github.com/marhali/easy-i18n
|
||||
# SemVer format -> https://semver.org
|
||||
pluginVersion = 4.4.1
|
||||
|
||||
# See https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
|
||||
# for insight into build numbers and IntelliJ Platform versions.
|
||||
# Supported build number ranges and IntelliJ Platform versions -> https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html
|
||||
pluginSinceBuild = 223
|
||||
pluginUntilBuild = 231.*
|
||||
pluginUntilBuild = 232.*
|
||||
|
||||
# IntelliJ Platform Properties -> https://github.com/JetBrains/gradle-intellij-plugin#intellij-platform-properties
|
||||
# IntelliJ Platform Properties -> https://plugins.jetbrains.com/docs/intellij/tools-gradle-intellij-plugin.html#configuration-intellij-extension
|
||||
platformType = IU
|
||||
platformVersion = 2022.3
|
||||
platformVersion = 2023.2.1
|
||||
|
||||
# Plugin Dependencies -> https://plugins.jetbrains.com/docs/intellij/plugin-dependencies.html
|
||||
# Example: platformPlugins = com.intellij.java, com.jetbrains.php:203.4449.22
|
||||
platformPlugins = org.jetbrains.kotlin, JavaScript, com.jetbrains.php:223.7571.182
|
||||
platformPlugins = org.jetbrains.kotlin, JavaScript, com.jetbrains.php:232.9559.64
|
||||
|
||||
# Gradle Releases -> https://github.com/gradle/gradle/releases
|
||||
gradleVersion = 7.5.1
|
||||
gradleVersion = 8.3
|
||||
|
||||
# Opt-out flag for bundling Kotlin standard library -> https://plugins.jetbrains.com/docs/intellij/kotlin.html#kotlin-standard-library
|
||||
# suppress inspection "UnusedProperty"
|
||||
# Opt-out flag for bundling Kotlin standard library -> https://jb.gg/intellij-platform-kotlin-stdlib
|
||||
kotlin.stdlib.default.dependency = false
|
||||
|
||||
# Enable Gradle Configuration Cache -> https://docs.gradle.org/current/userguide/configuration_cache.html
|
||||
org.gradle.unsafe.configuration-cache = true
|
||||
org.gradle.configuration-cache = true
|
||||
|
||||
# Enable Gradle Build Cache -> https://docs.gradle.org/current/userguide/build_cache.html
|
||||
org.gradle.caching = true
|
||||
|
||||
# Enable Gradle Kotlin DSL Lazy Property Assignment -> https://docs.gradle.org/current/userguide/kotlin_dsl.html#kotdsl:assignment
|
||||
systemProp.org.gradle.unsafe.kotlin.assignment = true
|
22
gradle/libs.versions.toml
Normal file
22
gradle/libs.versions.toml
Normal file
@ -0,0 +1,22 @@
|
||||
[versions]
|
||||
# libraries
|
||||
annotations = "24.0.1"
|
||||
json5-java = "2.0.0"
|
||||
|
||||
# plugins
|
||||
kotlin = "1.9.0"
|
||||
changelog = "2.1.2"
|
||||
gradleIntelliJPlugin = "1.15.0"
|
||||
qodana = "0.1.13"
|
||||
kover = "0.7.3"
|
||||
|
||||
[libraries]
|
||||
annotations = { group = "org.jetbrains", name = "annotations", version.ref = "annotations" }
|
||||
json5-java = { group = "de.marhali", name = "json5-java", version.ref = "json5-java" }
|
||||
|
||||
[plugins]
|
||||
changelog = { id = "org.jetbrains.changelog", version.ref = "changelog" }
|
||||
gradleIntelliJPlugin = { id = "org.jetbrains.intellij", version.ref = "gradleIntelliJPlugin" }
|
||||
kotlin = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
|
||||
kover = { id = "org.jetbrains.kotlinx.kover", version.ref = "kover" }
|
||||
qodana = { id = "org.jetbrains.qodana", version.ref = "qodana" }
|
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
BIN
gradle/wrapper/gradle-wrapper.jar
vendored
Binary file not shown.
4
gradle/wrapper/gradle-wrapper.properties
vendored
4
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,5 +1,7 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
25
gradlew
vendored
25
gradlew
vendored
@ -55,7 +55,7 @@
|
||||
# Darwin, MinGW, and NonStop.
|
||||
#
|
||||
# (3) This script is generated from the Groovy template
|
||||
# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
|
||||
# within the Gradle project.
|
||||
#
|
||||
# You can find Gradle at https://github.com/gradle/gradle/.
|
||||
@ -80,13 +80,11 @@ do
|
||||
esac
|
||||
done
|
||||
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
|
||||
|
||||
APP_NAME="Gradle"
|
||||
# This is normally unused
|
||||
# shellcheck disable=SC2034
|
||||
APP_BASE_NAME=${0##*/}
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
|
||||
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
|
||||
|
||||
# Use the maximum available, or set MAX_FD != -1 to use that value.
|
||||
MAX_FD=maximum
|
||||
@ -133,22 +131,29 @@ location of your Java installation."
|
||||
fi
|
||||
else
|
||||
JAVACMD=java
|
||||
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
if ! command -v java >/dev/null 2>&1
|
||||
then
|
||||
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
|
||||
|
||||
Please set the JAVA_HOME variable in your environment to match the
|
||||
location of your Java installation."
|
||||
fi
|
||||
fi
|
||||
|
||||
# Increase the maximum file descriptors if we can.
|
||||
if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
|
||||
case $MAX_FD in #(
|
||||
max*)
|
||||
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
MAX_FD=$( ulimit -H -n ) ||
|
||||
warn "Could not query maximum file descriptor limit"
|
||||
esac
|
||||
case $MAX_FD in #(
|
||||
'' | soft) :;; #(
|
||||
*)
|
||||
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
|
||||
# shellcheck disable=SC3045
|
||||
ulimit -n "$MAX_FD" ||
|
||||
warn "Could not set maximum file descriptor limit to $MAX_FD"
|
||||
esac
|
||||
@ -193,6 +198,10 @@ if "$cygwin" || "$msys" ; then
|
||||
done
|
||||
fi
|
||||
|
||||
|
||||
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
|
||||
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
|
||||
|
||||
# Collect all arguments for the java command;
|
||||
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
|
||||
# shell script including quotes and variable substitutions, so put them in
|
||||
|
1
gradlew.bat
vendored
1
gradlew.bat
vendored
@ -26,6 +26,7 @@ if "%OS%"=="Windows_NT" setlocal
|
||||
|
||||
set DIRNAME=%~dp0
|
||||
if "%DIRNAME%"=="" set DIRNAME=.
|
||||
@rem This is normally unused
|
||||
set APP_BASE_NAME=%~n0
|
||||
set APP_HOME=%DIRNAME%
|
||||
|
||||
|
@ -2,6 +2,8 @@
|
||||
# https://www.jetbrains.com/help/qodana/qodana-yaml.html
|
||||
|
||||
version: 1.0
|
||||
linter: jetbrains/qodana-jvm-community:latest
|
||||
projectJDK: 17
|
||||
profile:
|
||||
name: qodana.recommended
|
||||
exclude:
|
||||
|
@ -1 +1,5 @@
|
||||
plugins {
|
||||
id("org.gradle.toolchains.foojay-resolver-convention") version "0.6.0"
|
||||
}
|
||||
|
||||
rootProject.name = "easy-i18n"
|
||||
|
Loading…
x
Reference in New Issue
Block a user