From 5b6358d87458715cad02d51ee5cd944814d1db4a Mon Sep 17 00:00:00 2001 From: Antti Villberg Date: Tue, 14 Jan 2020 15:38:06 +0200 Subject: [PATCH 1/1] Support ontology install option trueWhenDeployed also during development gitlab #444 Change-Id: I038de840b1b76b3638338542d23baae2ba2a903f --- .../simantics/project/management/PlatformUtil.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java b/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java index af59dbfc1..8f93d24ab 100644 --- a/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java +++ b/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java @@ -479,7 +479,18 @@ public class PlatformUtil { private static boolean isImmutable(Bundle bundle) { String immutable = (String) bundle.getHeaders().get("Immutable"); - return immutable != null ? "true".equals(immutable) : true; + if(immutable == null) + return true; + if("false".equals(immutable)) + return false; + if("trueWhenDeployed".equals(immutable)) { + String installHint = System.getProperty("installOntologiesAsDeployed"); + if("true".equals(installHint)) + return true; + else + return false; + } + return true; } public static class TGInfo { -- 2.43.2