-
-
Notifications
You must be signed in to change notification settings - Fork 227
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
1031 fix java docker conflict #1077
Conversation
✅ Deploy Preview for dtc-docs-preview ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
The Header rules failed. |
2f493dd
to
36e0d8c
Compare
Since I got the macOS uses, due to licensing reasons, an ancient bash version, more precise bash 3.2. And bash arrays were introduced with bash 4. Since my refactoring uses associative arrays (hash map), it's not going to work on macOS. |
@rdmueller I have a question: does the current The bash version on macOS 12 is 3.5.57 $ bash --version
GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin18)
Copyright (C) 2007 Free Software Foundation, Inc. I could try to change So my question is: should we make Bash >= 4 for |
36e0d8c
to
f00f05b
Compare
I found a solution to both problems:
One problem remains: the output and behavior of |
1b62119
to
9cc29fb
Compare
@rdmueller Could you please take a look at the changes? The issues we have to address:
If we decide this goes into 2.3.0 we have to change the documentation on the page. |
9cc29fb
to
9293f53
Compare
it is used withing
I think it is mainly used to link to the correct branch for the
As far as I remember, the structure of the zipped JDK is different for Windows than for Linux. The windows one contains the
shouldn't be this way but it currently is. Within the docker image, reveal is already cloned into the image: https://github.com/docToolchain/docker-image/blob/ng-beta/alpine/Dockerfile#L52 But the wrapper ignored it, because something it wrong with the following block: https://github.com/docToolchain/docToolchain/blob/ng/dtcw#L122 it doesn't recognize reveal as already cloned. Workaround is not to use ´generateDeck |
afaik, this is a check coming from netlify. argh. netlify can't build the website because of the changed dtcw...
|
current version seems to work on macOS. Maybe we could try to detect outdated versions and ask the user to upgrade? |
I think we should align both. I can take a look at it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanx for the re-write. Seems to me that you are a bash wizard!
I commented on two things I would like to change.
And for the rest I have to admit that I am not too good at bash scripting to fully understand everything. So I would like to give it a try by releasing this as some kind of release candidate.
What do you think?
And btw - we should increase the version to 1.0, shouldn't we?
This would be fine. I would not merge this change into ng without the change in We really should think about what technology we should use for v3. Having 3 scripts for the same logic is error prone. |
Can we change this per branch basis? I never worked with netlify, so I have no idea where to adapt this. |
I think this one is set correctly.
What is the default value if
OK, I will add this information in the code.
OK, so the |
I would bump the version to 0.50 and go for test period. But first we have to adjust the changes in |
e1cf745
to
57a3c36
Compare
I adapted the documentation for the installation instructions. What we are missing now is the changes in the Windows wrapper scripts. |
I currently try to get netlify preview up and running, but I get the following error:
any idea? |
I will add a test case for Java 8. Could you provide the output of I will add a new test case with the output. |
The line above means if docToolchain is not installed (string empty), show
I use boolean logic as oneliner. The part after |
making progress. nearly through |
so, the powershell version has been rewritten to match the rewritten bash version. What are our next steps? |
Check and fix the documentation, address the minor issues from your feedback, manual testing, then integrate it. Regarding the documentation: have you found the reason why the formatting breaks at the end of the installation section? I will do that next week after my vacation. |
I just checked it and couldn't find it anymore?!? |
Then we have just to update the documentation (output) from the windows ps1 (and bat) scripts. Since you have a Mac, where do you test the ms windows environment? |
Since a few weeks, I own a Mac with M2pro chip for work and I do have a windows machine as my private workhorse. This gives me the flexibility to test everything. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great rewrite! I skimmed through the change and added some comments that may ease the rebase on ng
9ef4125
to
d526c12
Compare
I rebased this PR and removed the code to install reveal.js. |
d526c12
to
35ec1c2
Compare
I really would like to get this PR into the @rdmueller Is the re-write of |
@mh182 , yes, the rewrite should be complete. If we.merge it now, I also have time to fix upcoming problems quickly |
35ec1c2
to
1b08ce2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor issues to fix Last fixes before we can integrate.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am quite happy with these changes. let's merge!
- Fix bug docToolchain#1031 - Fix: support of JAVA_HOME which was silently ignored. - Add `--version` option - dtcw API change: use explicit 'install' command to install components locally. - Improve output: provide the concept of 'environments'. - Show deprecation of 'getJava' - Skip 'install doctoolchain' if already installed Refactorings: - Replace boolean flags which `available_environments` and `dtc_installations`. Tests: - Use mocks for dtcw test suite to improve performance. - Added end-to-end tests for installation in 'local' and 'sdk' environments.
08e91cc
to
2605b5c
Compare
This is a major refactoring of
dtcw
(I would rather say it is a rewrite). So it may make more sense to look at the complete file instead of a diff.The main goal of the refactoring was to make the code better understandable. Please provide feedback if this is true.
Note: the refactoring in
dtcw
is not meant to be complete.I'm going to focus in the PR on the implementation details. I will explain the user visible changes in #1031.
What changed:
dtcw
behaves with a hash-map.e2e_*.bats
)dtcw
coverageThe open questions we should discuss (marked with
# TODO
indtcw
):DTC_HEADLESS
and-Dgradle.user.home
work with Docker containers. When do we have to set which variable?DTC_SITETHEME
is never used (the environment flag to the docker container is never passed)DTC_PROJECT_BRANCH
good for? (not described anywhere but passed intodtcw
).doctoolchain/jdk/Content/Home
when looking for a JRE?generateDeck
can only be called in alocal
environment - is this correct?What is missing:
test/README.adoc
file)