Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
OS X Java vendor Extension attribute
#!/bin/sh
javaVendor=`defaults read /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Info CFBundleIdentifier`
if [ "$javaVendor" = "com.oracle.java.JavaAppletPlugin" ]; then
result=Oracle
elif [ "$javaVendor" = "com.apple.java.JavaAppletPlugin" ]; then
result=Apple
elif [ "$javaVendor" = "" ]; then
result="No Java Plug-In Available"
fi
echo "<result>$result</result>"
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment