<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Radek's Tech Blog &#187; FeaturesAndBundlesPublisher</title>
	<atom:link href="http://urbas.tk/index.php/tag/featuresandbundlespublisher/feed/" rel="self" type="application/rss+xml" />
	<link>http://urbas.tk</link>
	<description>Radoslaw H. Urbas homepage / blog</description>
	<lastBuildDate>Tue, 01 Jun 2010 20:31:19 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Generating p2 meta data from command line</title>
		<link>http://urbas.tk/index.php/2010/06/01/generating-p2-meta-data-from-command-line/</link>
		<comments>http://urbas.tk/index.php/2010/06/01/generating-p2-meta-data-from-command-line/#comments</comments>
		<pubDate>Tue, 01 Jun 2010 20:15:30 +0000</pubDate>
		<dc:creator>Radoslaw Urbas</dc:creator>
				<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[IT]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[eclipse]]></category>
		<category><![CDATA[FeaturesAndBundlesPublisher]]></category>
		<category><![CDATA[generating]]></category>
		<category><![CDATA[meta data]]></category>
		<category><![CDATA[p2]]></category>

		<guid isPermaLink="false">http://urbas.tk/?p=215</guid>
		<description><![CDATA[Many times when working with Eclipse RCP I had to generate ad-hoc updatesites (usually containing some 3rd party plug-ins). What I usually did to achieve this (with Eclipse IDE): create new feature project add plug-ins to the feature create new updatesite project add the feature to the updatesite (pre-p2 style &#8211; site.xml) export newly created updatesite [...]]]></description>
			<content:encoded><![CDATA[<p>Many times when working with Eclipse RCP I had to generate ad-hoc updatesites (usually containing some 3rd party plug-ins). What I usually did to achieve this (with Eclipse IDE):</p>
<ul>
<li>create new feature project</li>
<li>add plug-ins to the feature</li>
<li>create new updatesite project</li>
<li>add the feature to the updatesite (pre-p2 style &#8211; site.xml)</li>
<li>export newly created updatesite (letting Eclipse to deal with creating p2 meta data)</li>
</ul>
<p>Since I needed to automate this process I started researching on p2 capabilities and found out that it can be done from command line using FeatureAndBundlesPublisher application. Sample command line invocation to do it:</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;">%ECLIPSE_EXE% -application org.eclipse.equinox.p2.publisher.FeaturesAndBundlesPublisher -metadataRepository file:/%P2_TARGET% -artifactRepository file:/%P2_TARGET% -source %P2_SRC% -compress -configs win32.win32.x86 -publishArtifacts</pre></div></div>

<p>Where:</p>
<ul>
<li>ECLIPSE_EXE &#8211; points to Eclipse executable;</li>
<li>P2_TARGET &#8211; path to an empty directory where p2 repository should be created;</li>
<li>P2_SRC &#8211; path to the directory with /plugins subdirectory and plug-ins to be published (jar files) inside;</li>
<li><em>-compress</em> parameter is optional. It compresses artifacts.xml and content.xml to jar (zip) files.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://urbas.tk/index.php/2010/06/01/generating-p2-meta-data-from-command-line/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
	</channel>
</rss>

