How to include new binding to the openhab-runtime through eclipse ide

Hi,
I have followed all the procedure to run an openHAB version 2.5.x through eclipse as specified in Eclipse IDE | openHAB.

Now i have to add a new binding to the openHAB runtime and start to test and debug the binding through eclipse.

I have tried to import the new binding to the eclipse, added the binding dependency in pom.xml of org.openhab.demo.app as follows :

<dependency>
  <groupId>org.openhab.binding</groupId>
  <artifactId>org.openhab.binding.newbinding</artifactId>
  <version>${project.version}</version>
  <scope>runtime</scope>
</dependency> 

But when I save the pom.xml file the ide shows —> missing artifact error.

So what is the mistake i am doing. Please help me out in doing this.

Thanks in advance

This implies the version in the pom.xml of your binding must be the same as the version in pom.xml of the demo pom.xml. What versions do they have?

Thanks for the reply

As you said the pom.xml version of the binding that i am using is 2.0.0-SNAPSHOT. So, the demo’s pom.xml version is 2.5.0. Since the binding that i am using does not have updated version releases. I have to use the same binding as per my requirement.

To make my binding compatible with the demo’s pom.xml version, what is the procedure that needs to be followed.

If your binding is a different version as the demo pom it doesn’t make sense to use project.version. You need to replace it with the exact version of you binding. If the binding version is compatible with the demo version is not relevant as only te version number itself doesn’t mean anything here. As it’s an old binding you probably first needs to migrate the binding to the new build system. See this tutorial: Tutorial: Migrate your binding to the Maven + Bnd based build system Than it can be any version, just make sure to use the version of the binding instead of project.version.