[eclipse] Finding the Eclipse Version Number

I have posted how to find it in Eclipse Gallileo, but if anyone has information on older versions feel free to post it below.

This question is related to eclipse version

The answer is


There is a system property eclipse.buildId (for example, for Eclipse Luna, I have 4.4.1.M20140925-0400 as a value there).

I'm not sure in which version of Eclipse did this property become available.

Also, dive right in and explore all the available system properties -- there is quite a bit of information available under eclipse.*, os.* osgi.* and org.osgi.* namespaces.


UPDATE! After experimenting with different Eclipse versions, it seems that eclipse.buildId system property is not the way to go. For example, on Eclipse Luna 4.4.0, it gives the result of 4.4.2.M20150204-1700 which is obviously incorrect.

I suspect eclipse.buildId system property is set to the version of org.eclipse.platform plugin. Unfortunately, this does not (always) give the correct result. However, good news is that I have a solution with working code sample which I will outline in a separate answer.


In Eclipse Gallileo:

The about page (Help -> About Eclipse) has some icons towards the bottom of the dialogue. This should include two which are the plain Eclipse icon. Select the one with tooltip "Eclipse.org". Eclipse has many components, each of which has its own version number. The core is the Eclipse Platform


I think, the easiest way is to read readme file inside your Eclipse directory at path eclipse/readme/eclipse_readme .

At the very top of this file it clearly tells the version number:

For My Eclipse Juno; it says version as Release 4.2.0


if you want to access this programatically, you can do it by figuring out the version of eclipse\plugins\org.eclipse.platform_ plugin

    String platformFile = <the above file>; //actually directory

versionPattern = Pattern.compile("\\d\\.\\d\\.\\d");
Matcher m = versionPattern.matcher(platformFile);
return m.group();

For Eclipse Java EE IDE - Indigo: Help > About Eclipse > Eclipse.org (third from last). In the 'About Eclipse Platform' locate Eclipse Platform and you'll have the version beneath the Version Column. Hope this helps J2EE Indigo Users.


Here is a working code snippet that will print out the full version of currently running Eclipse (or any RCP-based application).

String product = System.getProperty("eclipse.product");
IExtensionRegistry registry = Platform.getExtensionRegistry();
IExtensionPoint point = registry.getExtensionPoint("org.eclipse.core.runtime.products");
Logger log = LoggerFactory.getLogger(getClass());
if (point != null) {
  IExtension[] extensions = point.getExtensions();
  for (IExtension ext : extensions) {
    if (product.equals(ext.getUniqueIdentifier())) {
      IContributor contributor = ext.getContributor();
      if (contributor != null) {
        Bundle bundle = Platform.getBundle(contributor.getName());
        if (bundle != null) {
          System.out.println("bundle version: " + bundle.getVersion());
        }
      }
    }
  }
}

It looks up the currently running "product" extension and takes the version of contributing plugin.

On Eclipse Luna 4.4.0, it gives the result of 4.4.0.20140612-0500 which is correct.


For Eclipse Kepler, there is no Help > About Eclipse but I found this works:

Eclipse > About Eclipse


1 - Open Eclipse IDE. 2 - Press: Alt + H 3 - Use keyboard arrows to go dwn the list 4 - Select About Eclipse IDE tab.


Based on Neeme Praks' answer, the below code should give you the version of eclipse ide you're running within.

In my case, I was running in an eclipse-derived product, so Neeme's answer just gave me the version of that product. The OP asked how to find the Eclipse version, whih is what I was after. Therefore I needed to make a couple of changes, leading me to this:

    /**
     * Attempts to get the version of the eclipse ide we're running in.
     * @return the version, or null if it couldn't be detected.
     */
    static Version getEclipseVersion() {
        String product = "org.eclipse.platform.ide";
        IExtensionRegistry registry = Platform.getExtensionRegistry();
        IExtensionPoint point = registry.getExtensionPoint("org.eclipse.core.runtime.products");
        if (point != null) {
            IExtension[] extensions = point.getExtensions();
            for (IExtension ext : extensions) {
                if (product.equals(ext.getUniqueIdentifier())) {
                    IContributor contributor = ext.getContributor();
                    if (contributor != null) {
                        Bundle bundle = Platform.getBundle(contributor.getName());
                        if (bundle != null) {
                            return bundle.getVersion();
                        }
                    }
                }
            }
        }
        return null;
    }

This will return you a convenient Version, which can be compared thus:

    private static final Version DESIRED_MINIMUM_VERSION = new Version("4.9"); //other constructors are available
    boolean haveAtLeastMinimumDesiredVersion()
        Version thisVersion = getEclipseVersion();
        if (thisVersion == null) {
            //we might have a problem
        }
        //returns a positive number if thisVersion is greater than the given parameter (desiredVersion)
        return thisVersion.compareTo(DESIRED_MINIMUM_VERSION) >= 0;
    }

Examples related to eclipse

How do I get the command-line for an Eclipse run configuration? My eclipse won't open, i download the bundle pack it keeps saying error log strange error in my Animation Drawable How to uninstall Eclipse? How to resolve Unable to load authentication plugin 'caching_sha2_password' issue Class has been compiled by a more recent version of the Java Environment Eclipse No tests found using JUnit 5 caused by NoClassDefFoundError for LauncherFactory How to downgrade Java from 9 to 8 on a MACOS. Eclipse is not running with Java 9 "The POM for ... is missing, no dependency information available" even though it exists in Maven Repository The origin server did not find a current representation for the target resource or is not willing to disclose that one exists. on deploying to tomcat

Examples related to version

Which TensorFlow and CUDA version combinations are compatible? How can the default node version be set using NVM? Node - was compiled against a different Node.js version using NODE_MODULE_VERSION 51 Which ChromeDriver version is compatible with which Chrome Browser version? How to find which version of TensorFlow is installed in my system? How to update Ruby Version 2.0.0 to the latest version in Mac OSX Yosemite? What does 'Unsupported major.minor version 52.0' mean, and how do I fix it? Find nginx version? How to check all versions of python installed on osx and centos How can I specify the required Node.js version in package.json?