[Build] CI refactor (#149)
* [Build] CI refactor * [Build] Fix GenerateLibs * [Build] Up actions/checkout@v3 * [Build] Remove actions/gradle-build-action * [Build] Uncomment publish/release jobs * [Build] Delete obsolete jobs * [Build] Add more info to the jar manifest * [Build] Make checkout to fetch tags * [Build] Return job to update binaries * [Doc] Update README
This commit is contained in:
1 parent
62377c7b1d
commit
2957cb4b88
24 files changed
+290
-352
No files matched your search
@@ -1,35 +0,0 @@
|
||||
package tool
|
||||
|
||||
import org.gradle.api.DefaultTask
|
||||
import org.gradle.api.tasks.Internal
|
||||
import org.gradle.api.tasks.TaskAction
|
||||
|
||||
class UpVersion extends DefaultTask {
|
||||
@Internal
|
||||
String group = 'build'
|
||||
@Internal
|
||||
String description = 'Up project version to the next one.'
|
||||
|
||||
@TaskAction
|
||||
void up() {
|
||||
String currentVersion = project.findProperty('version')
|
||||
String nextVersion = project.findProperty('next')
|
||||
|
||||
if (!currentVersion) {
|
||||
throw new IllegalStateException('No property was found: "version"')
|
||||
}
|
||||
if (!nextVersion) {
|
||||
throw new IllegalStateException('No property was found: "next"')
|
||||
}
|
||||
|
||||
println "Up project version: $nextVersion..."
|
||||
|
||||
println 'Updating gradle.properties...'
|
||||
def propsFile = project.file('gradle.properties')
|
||||
propsFile.text = propsFile.text.replace("version=$currentVersion", "version=$nextVersion")
|
||||
|
||||
println 'Updating README.md...'
|
||||
def readmeFile = project.file('README.md')
|
||||
readmeFile.text = readmeFile.text.replace(currentVersion, nextVersion)
|
||||
}
|
||||
}
|
||||
@@ -16,9 +16,9 @@ class GenerateLibs extends DefaultTask {
|
||||
String description = 'Generate imgui-java native binaries.'
|
||||
|
||||
private final String[] buildEnvs = System.getProperty('envs')?.split(',')
|
||||
private final boolean forWindows = buildEnvs?.contains('win')
|
||||
private final boolean forWindows = buildEnvs?.contains('windows')
|
||||
private final boolean forLinux = buildEnvs?.contains('linux')
|
||||
private final boolean forMac = buildEnvs?.contains('mac')
|
||||
private final boolean forMac = buildEnvs?.contains('macos')
|
||||
|
||||
private final boolean isLocal = System.properties.containsKey('local')
|
||||
private final boolean withFreeType = Boolean.valueOf(System.properties.getProperty('freetype', 'false'))
|
||||
|
||||
Reference in new issue
Block a user