John, thanks for the kind words. I’m really glad to see that the article has been useful.
You raise some useful and important points. Let’s look at them one at a time.
Firstly, you ask about the switch -PjavafxJmodsPath. The article represents a point in time at the beginning of a journey and the project has now evolved since that point. The good news is that it is no longer necessary to include that switch as the jmods are now all downloaded from Maven Central. You can see the details of the change in this issue on the VocabHunter repository (I made the changes there and then copied them across to Santulator). I think that this is a big improvement as it makes the build process simpler and less error prone.
Secondly, you ask about the reason for calling the Java Packager class directly on Windows rather than calling the executable. The answer is that this was a pragmatic decision, after I had some problems with the Windows build. I first tried doing things as you suggest but found that I ran into errors stating “java.lang.module.FindException: Module jdk.packager not found”. The simple solution to this was to call the Java directly and specify the correct module path. However, if there is a better solution I’d be keen to know to see if it can be used instead for Santulator and VocabHunter.
Finally, you ask about the install directory. Again, this is an interesting point. The directory size is large and I’m sure there are ways to cut it down. I think this would be a useful thing to do. Perhaps the version of the Java Packager coming with JDK 13 later this year will help with that. In the meantime I ran a quick test and downloaded and installed Santulator 1.1.0 onto a fresh Windows virtual machine. I checked the files in the root directory and there’s not a whole lot there. I only see 10 files, aside from the subdirectories. And of those 10 files, the biggest is just 941Kb. Do you see something different if you try the same?
Again, thanks John for engaging with this. The great thing about Open Source is that by sharing our work, issue descriptions, pull requests, workarounds and experience we are able to help one another. Your feedback and questions are an important part of this process.