Skip to content

Commit

Permalink
Upgrade for a 2023.1-Alpha Release
Browse files Browse the repository at this point in the history
  • Loading branch information
Garethp committed Apr 16, 2023
1 parent 3b71ca1 commit 8e35913
Show file tree
Hide file tree
Showing 15 changed files with 225 additions and 169 deletions.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

49 changes: 27 additions & 22 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ import org.apache.tools.ant.taskdefs.condition.Os

plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm' version '1.5.30'
id 'org.jetbrains.intellij' version '1.7.0' // https://github.com/JetBrains/gradle-intellij-plugin/releases
id 'com.jetbrains.rdgen' version '0.213.391' // https://www.myget.org/feed/rd-snapshots/package/maven/com.jetbrains.rd/rd-gen
id 'org.jetbrains.kotlin.jvm' version '1.8.20'
id 'org.jetbrains.intellij' version '1.13.3' // https://github.com/JetBrains/gradle-intellij-plugin/releases
id 'com.jetbrains.rdgen' version '2023.2.0' // https://www.myget.org/feed/rd-snapshots/package/maven/com.jetbrains.rd/rd-gen
}

ext {
Expand All @@ -21,7 +21,7 @@ repositories {
}

wrapper {
gradleVersion = '7.1'
gradleVersion = '7.3'
distributionType = Wrapper.DistributionType.ALL
distributionUrl = "https://cache-redirector.jetbrains.com/services.gradle.org/distributions/gradle-${gradleVersion}-all.zip"
}
Expand All @@ -42,22 +42,26 @@ compileKotlin {

task setBuildTool {
doLast {
ext.args = []
ByteArrayOutputStream stdout = new ByteArrayOutputStream()
ext.executable = "dotnet"
ext.args = ["msbuild"]

if (isWindows) {
ByteArrayOutputStream stdout = new ByteArrayOutputStream()
exec {
executable "${rootDir}\\tools\\vswhere.exe"
args '-latest','-property','installationPath','-products','*'
standardOutput = stdout
workingDir rootDir
}
List<String> files = new FileNameFinder().getFileNames("${stdout.toString().trim()}\\MSBuild", "**/MSBuild.exe")
ext.executable = files.get(0)
ext.args << "/v:minimal"
} else {
ext.executable = "dotnet"
ext.args << "msbuild"

def directory = "C:\\Users\\**\\.dotnet"
if (directory) {
List<String> files = new FileNameFinder().getFileNames("${directory}", "**/dotnet.exe")
ext.executable = files.get(0)
ext.args = ["/v:minimal"]
}
}

ext.args << "${DotnetSolution}"
ext.args << "/p:Configuration=${BuildConfiguration}"
ext.args << "/p:HostFullIdentifier="
Expand All @@ -77,6 +81,7 @@ task compileDotNet {
}
}


buildPlugin {
doLast {
copy {
Expand All @@ -91,16 +96,16 @@ buildPlugin {
it[1].replaceAll(/(?s)- /, "\u2022 ").replaceAll(/`/, "").replaceAll(/,/, "%2C").replaceAll(/;/, "%3B")
}.take(1).join("")

def arguments = setBuildTool.args.clone()
arguments << "/t:Pack"
arguments << "/p:PackageOutputPath=${rootDir}/output"
arguments << "/p:PackageReleaseNotes=${changeNotes}"
arguments << "/p:PackageVersion=${version}"
exec {
executable setBuildTool.executable
args arguments
workingDir rootDir
}
// def arguments = setBuildTool.args.clone()
// arguments << "/t:Pack"
// arguments << "/p:PackageOutputPath=${rootDir}/output"
// arguments << "/p:PackageReleaseNotes=${changeNotes}"
// arguments << "/p:PackageVersion=${version}"
// exec {
// executable setBuildTool.executable
// args arguments
// workingDir rootDir
// }
}
}

Expand Down
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@
DotnetPluginId=ReSharperPlugin.RimworldDev
DotnetSolution=ReSharperPlugin.RimworldDev.sln
RiderPluginId=com.jetbrains.rider.plugins.rimworlddev
PluginVersion=9999.0.0
PluginVersion=2023.1-ALPHA

BuildConfiguration=Debug
BuildConfiguration=Release

PublishToken="_PLACEHOLDER_"

# Possible values (minor is omitted):
# Release: 2020.2
# Nightly: 2020.3-SNAPSHOT
# EAP: 2020.3-EAP2-SNAPSHOT
ProductVersion=2022.2
ProductVersion=2023.1

# Kotlin 1.4 will bundle the stdlib dependency by default, causing problems with the version bundled with the IDE
# https://blog.jetbrains.com/kotlin/2020/07/kotlin-1-4-rc-released/#stdlib-default
Expand Down
Binary file removed gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
5 changes: 0 additions & 5 deletions gradle/wrapper/gradle-wrapper.properties

This file was deleted.

Loading

0 comments on commit 8e35913

Please sign in to comment.