Oracle support EOL for Java LTS versions

The current end of life support dates are interesting. I extracted some dates from the official support table to make it easier to see this.

VersionGeneral AvailabilityPRemiereExtended

First of all, extended support for Java 7 is less than a year away. You aren’t still on Java 7, right? 🙂

Second, premiere support for Java 11 ends later than Java 8. However, extended support for Java 8 ends way later. This is interesting. I guess Oracle recognizes it is harder to move off Java 8 than other versions?

Announcing the New Java 17 1Z0-829 Certification Exam and Study Guides!

Scott and Jeanne are thrilled to announce that Oracle has finally announced the new Java 17 1Z0-829 exam! Having worked with Oracle to create the objectives, we’ve been anxiously waiting to let all of our readers know that we already have two books for the new exam well underway:

In fact, you can preorder the Java 17 Complete Study Guide now!

The exam is similar to the Java 11 1Z0-819 that preceded it. The following are some of the key changes Oracle has made to the new exam:

  • Sealed Classes and Records have been added
  • Switch Expressions have been added
  • Pattern Matching has been added
  • Text Blocks have been added
  • Math API is on the exam
  • Date/Time API is back on the exam (previously on the Java 8 exam)
  • Annotations and Security have been removed

We’ll post more details soon about the exam including when you can sign up to take it, as Oracle releases the information!

running vs code from the command line on mac

Today was my FIRST in person FRC (FIRST Robotics Challenge) meeting since COVID showed up. Very exciting! Right now the older students are teaching the younger students. Today was an excellent intro the the UNIX/Git Bash command line. Towards the end, they showed that you can type “code” at the Git Bash prompt and have VS Code open automatically. Then a student asked how to do it on Mac.

There’s an easy way to do it and a hard way to do it. I went with the hard way because I thought I knew what to do. If we had gone the easy way, we would have been done in the meeting. Which proves the point of the importance of reading documentation.

The easy way

Courtesy of the setup docs for Mac

  1. Open VS Code (using Spotlight Search/the UI)
  2. Open the command palette (command + shift + p)
  3. Type path
  4. Choose option Shell Command: Install ‘code’ command in PATH command.
  5. Close VS Code
  6. Open a new terminal window
  7. Type code

The hard way

I divided the hard way into five steps to explain what to do. We got through step 1 and the beginning of step 2 during the meeting.

The Hard Way – Step 1: Find VS Code

I expected VS Code to be in /Applications. On my computer, it is at /Applications/Visual Studio That was not where the student had it. After some googling and failed attempts at using Stack Overflow threads, we found an excellent tip.

  1. Hold option and click the Apple in the top nav
  2. Choose “System Information”
  3. Software > Applications
  4. Wait patiently. No really. Wait some more
  5. Scroll all the way down to “V” and click “Visual Studio Code”
  6. Read the location. It was under <user home>/wpiilib/vscode or something like that. (WPILive is the robotics library)

The student had the good idea to open it in Finder and drag to /Applications. (Open finder and hold option while choosing “Go”) for extra options.

The Hard Way – Step 2: Figure out where “code” executable is and add to PATH

We poked around in the Visual Studio folder but ran out of meeting time. At home, I tried again; this time using the find command

% pwd
/Applications/Visual Studio
% find . -name code -print

Ok. Then. It’s under Contents/Resources/app./bin/code in side the app directory. I knew it was somewhere in there.

The Hard Way – Step 3: Add to PATH

If you are still on the old shell, add the following line to your <user home>/.bash_profile file. If you’ve switched to zsh, use the .zshrc file instead.

export PATH="$PATH:/Applications/Visual Studio"

The Hard Way – Step 4: Reload the file

Run one of these to run the file you just edited and have your change take effect

source .bash_profile
source .zshrc

The Hard Way – Step 5: Launch VS Code