How do I work with development build on macOS – NetBeans 11.0
Whenever you download NetBeans 11.0 (development version) from the official page here: Download, you end up with a zip file that contains working copy of NetBeans. It looks like this
netbeans |-- CREDITS.html |-- DEPENDENCIES |-- DISCLAIMER |-- LICENSE |-- NOTICE |-- README.html |-- apisupport |-- bin |-- enterprise |-- ergonomics |-- etc |-- extide |-- groovy |-- harness |-- ide |-- java |-- javafx |-- licenses |-- nb |-- netbeans.css |-- php |-- platform |-- profiler |-- webcommon `-- websvccommon
If you want to run it, you can make a symlink to netbeans/bin/netbeans, you can open the directory and double-click the executable file, you can put in on PATH. You have numerous options. However, macOS users (like me) are used to run everything from /Applications folder. This is why I have prepared very simple setup for my testing environment.
I have this small empty structure inside /Applications
NetBeans.app |-- Contents | |-- Info.plist | |-- MacOS | `-- netbeans.content `-- Icon\r
Info.plist is just an empty shell that is supposed to make macOS happy with application structure.
> cat Info.plist <plist><dict></dict></plist>
More interesting part of this “wrapper” lays here MacOS/NetBeans. As you can see, I simply run whatever comes bundled inside development version of NetBeans.
> cat MacOS/NetBeans #!/usr/bin/env bash ABSPATH=$(cd "$(dirname "$0")"; pwd) ${ABSPATH}/../netbeans.content/bin/netbeans
All I have to do, each time new version of NetBeans is ready, is drag and drop content of zip file inside /Applications/NetBeans.app/Contents/netbeans.content. Since now, I can run NetBeans directly from /Applications folder.
If you don’t want to waste your time reinventing the wheel, you can always download “empty shell” here: Download
After you open it, just drag and drop NetBeans inside /Application. Then, make sure to right click it and choose: Show Package Contents. Navigate to Contents -> netbeans.contents. Drop here the whole content of netbeans directory after unpacking development version of NetBeans.