<%String stepName = new GenerationHelper().getPositionString(publishStep);%> | |
<target name="<%=stepName%>" depends="init,install.buckminster" > | |
<%String featurename = publishStep.getComponent().getName();%> | |
<%String publishdirectory = "${publish}/" + featurename;%> | |
<echo message="Generate Site"/> | |
<buckminster command="perform"> | |
<globargs> | |
<arg value="-Dsite.include.top=true"/> | |
<arg value="-Dsite.signing=<%=publishStep.isSigning()%>"/> | |
<arg value="-Dcbi.include.source=<%=publishStep.isGenerateSources()%>"/> | |
</globargs> | |
<cmdargs> | |
<arg value="<%=featurename%>:eclipse.feature#site.p2" /> | |
</cmdargs> | |
</buckminster> | |
<echo message="Publish site"/> | |
<mkdir dir="<%=publishdirectory%>/site.p2/"/> | |
<copy todir="<%=publishdirectory%>/site.p2/"> | |
<fileset dir="${result}/output"> | |
<include name="<%=featurename%>*/site.p2/*"/> | |
<include name="<%=featurename%>*/site.p2/**"/> | |
</fileset> | |
<filtermapper> | |
<replaceregex pattern=".*site\.p2" replace="" /> | |
</filtermapper> | |
</copy> | |
<echo message="Publish dropins"/> | |
<condition property="site.src" value="site.signed" else="site"> | |
<istrue value="${site.signing}" /> | |
</condition> | |
<copy todir="<%=publishdirectory%>/dropins/<%=featurename%>/eclipse/"> | |
<fileset dir="${result}/output"> | |
<include name="<%=featurename%>*/${site.src}/plugins/*.jar"/> | |
<include name="<%=featurename%>*/${site.src}/features/*.jar"/> | |
</fileset> | |
<filtermapper> | |
<replaceregex pattern=".*_.*-eclipse\.feature.${site.src}.plugins" replace="plugins" /> | |
<replaceregex pattern=".*_.*-eclipse\.feature.${site.src}.features" replace="features" /> | |
</filtermapper> | |
</copy> | |
<buckminster command="perform"> | |
<globargs> | |
<arg value="-DsiteDir=<%=publishdirectory%>/dropins/<%=featurename%>/eclipse/" /> | |
</globargs> | |
<cmdargs> | |
<%BuildStep buildStep = publishStep.getComponent().getBuildStep();%> | |
<%String buildStepName = new GenerationHelper().getPositionString(buildStep);%> | |
<arg value="<%=buildStepName%>:buckminster#convertSiteToRuntime" /> | |
</cmdargs> | |
</buckminster> | |
<pathconvert property="featurefile<%=stepName%>"> | |
<first count="1"> | |
<fileset dir="${result}/output" includes="<%=featurename%>*eclipse.feature/temp/feature.xml" /> | |
</first> | |
</pathconvert> | |
<loadfile property="featureversion<%=stepName%>" srcFile="${featurefile<%=stepName%>}"> | |
<filterchain> | |
<striplinebreaks/> | |
<replaceregex | |
pattern="^.*<feature[^>]*version="([^"]*)".*$" | |
replace="\1"/> | |
</filterchain> | |
</loadfile> | |
<touch file="<%=publishdirectory%>/dropins/<%=featurename%>/<%=featurename%>_version_${featureversion<%=stepName%>}" /> | |
</target> | |