Github user ahgittin commented on a diff in the pull request:
https://github.com/apache/incubator-brooklyn/pull/722#discussion_r33456625
--- Diff:
software/base/src/main/java/brooklyn/entity/java/JavaSoftwareProcessSshDriver.java
---
@@ -336,7 +336,7 @@ protected int tryJavaInstall(String version, String
command) {
log.debug("Checking Java version at {}@{}", getEntity(),
getLocation());
// sed gets stdin like 'java version "1.7.0_45"'
ProcessTaskWrapper<Integer> versionCommand =
Entities.submit(getEntity(), SshTasks.newSshExecTaskFactory(
- getLocation(), "java -version 2>&1 | grep \"java version\"
| sed 's/.*\"\\(.*\\).*\"/\\1/'"));
+ getLocation(), "java -version 2>&1 | grep \" version\" |
sed 's/.*\"\\(.*\\).*\"/\\1/'"));
--- End diff --
not sure how universal `grep -E` is so i'd be against that. can you add a
mention to `openjdk version "1.8.0_45"` in the comment? things get missed in
the git history, especially if not on the first line (although they shouldn't
-- apologies from me for not noticing it!)
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---