You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by ah...@apache.org on 2022/03/15 08:23:11 UTC
[isis] branch master updated: ISIS-2877: polishing prev. commit
This is an automated email from the ASF dual-hosted git repository.
ahuber pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git
The following commit(s) were added to refs/heads/master by this push:
new 6b6bffd ISIS-2877: polishing prev. commit
6b6bffd is described below
commit 6b6bffddfa8cfe6828cf0b8d22eb075b13d36aa2
Author: Andi Huber <ah...@apache.org>
AuthorDate: Tue Mar 15 09:23:03 2022 +0100
ISIS-2877: polishing prev. commit
---
.../java/org/apache/isis/commons/internal/os/_OsUtil.java | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/commons/src/main/java/org/apache/isis/commons/internal/os/_OsUtil.java b/commons/src/main/java/org/apache/isis/commons/internal/os/_OsUtil.java
index 43f62d0..02b7637 100644
--- a/commons/src/main/java/org/apache/isis/commons/internal/os/_OsUtil.java
+++ b/commons/src/main/java/org/apache/isis/commons/internal/os/_OsUtil.java
@@ -50,9 +50,11 @@ public class _OsUtil {
public static enum OS {
WINDOWS,
LINUX,
- MAC,
+ MAC_OS,
OTHER;
- public boolean isWindows() { return this==WINDOWS;}
+ public boolean isWindows() { return this==WINDOWS; }
+ public boolean isLinux() { return this==LINUX; }
+ public boolean isMacOs() { return this==MAC_OS; }
}
public OS currentOs() {
@@ -63,7 +65,7 @@ public class _OsUtil {
return OS.LINUX;
}
if (System.getProperty("os.name").toLowerCase().contains("mac")) {
- return OS.MAC;
+ return OS.MAC_OS;
}
return OS.OTHER;
}
@@ -115,10 +117,10 @@ public class _OsUtil {
break;
case LINUX:
//XXX implement eventually
- case MAC:
+ case MAC_OS:
//XXX implement eventually
default:
- throw _Exceptions.unsupportedOperation("OS " + os + "not yet supported");
+ throw _Exceptions.unsupportedOperation("OS " + os + " not (yet) supported");
}
rt.exec(cmd);
}