Skip to content

Commit

Permalink
fix: ensure cache jdks directory exists before creating link (#1503)
Browse files Browse the repository at this point in the history
  • Loading branch information
oliv37 authored Nov 8, 2022
1 parent 5227a95 commit cd1f71f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main/java/dev/jbang/net/JdkManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@ public static void linkToExistingJdk(String path, int version) {
if (ver.isPresent()) {
Integer linkedJdkVersion = ver.get();
if (linkedJdkVersion == version) {
Util.mkdirs(jdkPath.getParent());
Util.createLink(jdkPath, linkedJdkPath);
Util.infoMsg("JDK " + version + " has been linked to: " + linkedJdkPath);
} else {
Expand Down

0 comments on commit cd1f71f

Please sign in to comment.