You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by he...@apache.org on 2014/07/01 12:40:07 UTC
[6/6] git commit: Add comments for #29.
Add comments for #29.
Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/490ebbd8
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/490ebbd8
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/490ebbd8
Branch: refs/heads/master
Commit: 490ebbd86acd2120780da31c1809b70b8c90f40a
Parents: 71e3a75
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Tue Jul 1 11:39:33 2014 +0100
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Tue Jul 1 11:39:33 2014 +0100
----------------------------------------------------------------------
utils/common/src/main/java/brooklyn/util/os/Os.java | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/490ebbd8/utils/common/src/main/java/brooklyn/util/os/Os.java
----------------------------------------------------------------------
diff --git a/utils/common/src/main/java/brooklyn/util/os/Os.java b/utils/common/src/main/java/brooklyn/util/os/Os.java
index f2ca037..ac474d5 100644
--- a/utils/common/src/main/java/brooklyn/util/os/Os.java
+++ b/utils/common/src/main/java/brooklyn/util/os/Os.java
@@ -174,12 +174,15 @@ public class Os {
return System.getProperty("user.home");
}
- /** merges paths using forward slash (unix way); see {@link Urls#mergePaths(String...)} */
+ /** merges paths using forward slash (unix way);
+ * now identical to {@link Os#mergePaths(String...)} but kept for contexts
+ * where caller wants to indicate the target system should definitely be unix */
public static String mergePathsUnix(String ...items) {
return Urls.mergePaths(items);
}
- /** merges paths using the local file separator */
+ /** merges paths using forward slash as the "local OS file separator", because it is recognised on windows,
+ * making paths more consistent and avoiding problems with backslashes being escaped */
public static String mergePaths(String ...items) {
char separatorChar = '/';
StringBuilder result = new StringBuilder();