Since there is a chance that I will have to do it again, and I donβt remember how to do it next time, I will write the following steps:
I created a p2.inf file with instructions;
instructions.configure=\ org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type:0,location:http${#58}//<my_url_here>,name:<my_name_here>,enabled:true);\ org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type:1,location:http${#58}//<my_url_here>,name:<my_name_here>,enabled:true);\ org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type:0,location:http${#58}//<my_url_here>,name:<my_name_here>,enabled:true);\ org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type:1,location:http${#58}//<my_url_here>,name:<my_name_here>,enabled:true);`
According to the Eclipse inf wiki, the file can be placed in the same directory as my feature.xml , so what I did is
I had a product consisting of this function, so I exported the product using the Eclipse Product Export Wizard. I have definitely built a repository.
After the assembly was completed, the content.jar file was in the repository. Inside content.jar was a content.xml file. Having studied it, I was able to find:
<touchpointData size='1'> <instructions size='1'> <instruction key='configure'> org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(<all my update sites>); </instruction> </instructions> </touchpointData>
So, this confirmed that the export did see my p2.inf file and did something with it.
To install from the repository, I used the Eclipse Director script:
cmd /c "C:\Program\Eclipse\director\director -consoleLog -bundlepool c:/program/eclipse/eclipse3.6_custom -profileProperties "org.eclipse.update.install.features=true" -i MyProduct.Product -r "file:/C:\eclipse\exported\repository" -dc:/program/eclipse/eclipse3.6_custom -p helios"`
The script installed the product from the repository to the destination.