Updating your JBossTools manifest.mf files for Indigo

Explanation

 

Since Indigo is a new version of eclipse and a new version of all our dependencies, we're going to become more strict on how we declare our eclipse dependencies. As of now, most plugins have a tendency to *not* declare version ranges in their manifest.mf, and we're going to begin to change that. One of the tools we will use in the future is API tooling that comes with eclipse to check backwards compatibility, but that will come later. In preparation for that, we are going to declare our new baseline to be the Indigo GA release.

 

 

What does this mean for my plugins?

 

Your plugins will need to change all dependency references in the MANIFEST.MF file to declare a minimum dependency of indigo, or, at this time, Indigo m5. At this time we'll only be doing this for eclipse plugin dependencies, and not other JBossTools plugins. The full task is a big long and involves finding out what version of every dependency Indigo will include. This has already been done, and the file listing all the versions is here: https://svn.jboss.org/repos/jbosstools/workspace/rstryker/manifestVersions/FixManifests/src/data.mf

 

This still doesn't make it much easier, so a small utility app has been made.

 

Getting the utility Project

 

mkdir tmp

cd tmp

svn co https://svn.jboss.org/repos/jbosstools/workspace/rstryker/manifestVersions/

cd manifestVersions/FixManifests/bin

vi run.sh

 

# Now update the script's tmpfileloc and rootFolder to show what file you want to be used

# as a temporary file, and where your root JBossTools repo is.

# The component will be passed in when running this script

# When done... go ahead and...

 

# ./run.sh {yourComponentName}

./run.sh jmx | sh

 

The script itself (run.sh) actually simply generates commands to execute, which

we pipe into sh to ensure they are run. An example command generated by using

the script is as follows:

 

java Main ../src/data.mf /home/rob/code/jbtools/jbosstools/trunk/jmx/plugins/org.jboss.tools.jmx.ui/META-INF/MANIFEST.MF > ~/tmpFile && mv ~/tmpFile /home/rob/code/jbtools/jbosstools/trunk/jmx/plugins/org.jboss.tools.jmx.ui/META-INF/MANIFEST.MF

 

The script will now REPLACE all your manifest.mf files for the chosen component.

You can now refresh your eclipse environment and make sure all manifest files

have been updated appropriately. Make sure there are no compile errors

and make sure nothing horrible has changed.

You can also check via command line by going into your component folder

and performing

          svn diff

 

 

But.... I'm not on linux!

 

No worries, friend! You can execute the java command yourself!

 

   java Main ../src/data.mf /path/to/your/svn/trunk/component/plugins/org.jboss.first.plugin

 

This will output to standard out a new Manifest file. You can save the output in the appropriate

manifest file directly, copy-paste it, or whatever method you want.