From 860778abec48e36cc36e6f7b87572cdfbe4b0103 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergej=20Ko=C5=A1=C4=8Dejev?= Date: Fri, 26 Jan 2024 14:25:37 +0100 Subject: [PATCH 1/3] Simplify build * Remove Maven local repository * Use new-style plugin declarations * Remove Gradle wrapper configuration, it is redundant. --- build.gradle | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/build.gradle b/build.gradle index 335e563bf6..df756f4358 100644 --- a/build.gradle +++ b/build.gradle @@ -1,23 +1,14 @@ plugins { id 'de.itemis.mps.gradle.common' version '1.13.+' id "com.github.breadmoirai.github-release" version "2.4.1" + id 'maven-publish' + id 'base' } -apply plugin: 'maven-publish' -apply plugin: 'base' - - - import de.itemis.mps.gradle.* import java.time.LocalDateTime - -wrapper { - gradleVersion '7.4.1' - distributionType 'all' -} - // detect if we are in a CI build if (project.hasProperty("forceCI")) { ext.ciBuild = true @@ -62,9 +53,6 @@ if (!project.hasProperty('nexusUsername')) { } logger.info 'Repository username: {}', project.nexusUsername -ext.dependencyRepositories = [ - 'https://artifacts.itemis.cloud/repository/maven-mps/' -] // Dependency versions // major version, e.g. '2021.1', '2021.2' @@ -123,12 +111,7 @@ dependencies { } repositories { - mavenLocal() - for (repoUrl in project.dependencyRepositories) { - maven { - url repoUrl - } - } + maven { url 'https://artifacts.itemis.cloud/repository/maven-mps/' } } ext.skipResolveMps = project.hasProperty('mpsHomeDir') From 5ff941f868817555a1d133d3cad4fd807221e632 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergej=20Ko=C5=A1=C4=8Dejev?= Date: Sun, 28 Jan 2024 09:51:16 +0100 Subject: [PATCH 2/3] Disable incremental build It fails if no model is modified due to a bug, and it is also not correct for build scripts. --- build.gradle | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/build.gradle b/build.gradle index df756f4358..dad2b0a6a8 100644 --- a/build.gradle +++ b/build.gradle @@ -198,14 +198,13 @@ ext.artifacts_dir = '-Dartifacts.root=' + artifactsDir ext.pluginVersion = "-DversionNumber=" + version ext.buildDate = "-DbuildDate=" + new Date().toString() ext.extensions_home = '-Dextensions.home=' + rootDir -ext.skipUnmodifiedModels = "-Dmps.generator.skipUnmodifiedModels=true" //incremental build support // ___________________ utilities ___________________ File scriptFile(String relativePath) { new File("$rootDir/build/generated/$relativePath") } -def defaultScriptArgs = [mps_home, build_dir, artifacts_dir, ext.buildDate, ext.pluginVersion, ext.skipUnmodifiedModels] +def defaultScriptArgs = [mps_home, build_dir, artifacts_dir, ext.buildDate, ext.pluginVersion] // enables https://github.com/mbeddr/mps-gradle-plugin#providing-global-defaults ext["itemis.mps.gradle.ant.defaultScriptArgs"] = defaultScriptArgs From a315b8b2adc38ae119504f022068fdc8063aba7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergej=20Ko=C5=A1=C4=8Dejev?= Date: Sun, 28 Jan 2024 13:09:02 +0100 Subject: [PATCH 3/3] Fail build when tests fail --- .../models/de.itemis.mps.extensions.build.mps | 36 +++++++++++-------- 1 file changed, 21 insertions(+), 15 deletions(-) diff --git a/code/build/solutions/de.itemis.mps.extensions.build/models/de.itemis.mps.extensions.build.mps b/code/build/solutions/de.itemis.mps.extensions.build/models/de.itemis.mps.extensions.build.mps index 3c0eca5339..f4db66670c 100644 --- a/code/build/solutions/de.itemis.mps.extensions.build/models/de.itemis.mps.extensions.build.mps +++ b/code/build/solutions/de.itemis.mps.extensions.build/models/de.itemis.mps.extensions.build.mps @@ -32,6 +32,7 @@ + @@ -929,16 +930,6 @@ - - - - - - - - - - @@ -958,6 +949,16 @@ + + + + + + + + + + @@ -13156,11 +13157,6 @@ - - - - - @@ -13201,6 +13197,11 @@ + + + + + @@ -19867,6 +19868,11 @@ + + + + +