Skip to content
Snippets Groups Projects
Commit 0ae00bb6 authored by david_williams's avatar david_williams
Browse files

prep for update site

parent fe131894
No related branches found
No related tags found
No related merge requests found
No preview for this file type
......@@ -68,24 +68,24 @@ if [ $clean ] ; then
fi
echo " Updating index and web site files, and site.xml file"
rsync -rp "${buildrepositorypath}"/* "${testUpdateSite}"
rsync -p ${HOME}/${updateToolsDir}/WebContent/${mainIndexFileName} ${testUpdateSite}/index.html
rsync -p ${HOME}/${updateToolsDir}/WebContent/*.jpg ${testUpdateSite}
rsync -vrp "${buildrepositorypath}"/* "${testUpdateSite}"
rsync -vp ${HOME}/${updateToolsDir}/WebContent/${mainIndexFileName} ${testUpdateSite}/index.html
rsync -vp ${HOME}/${updateToolsDir}/WebContent/*.jpg ${testUpdateSite}
echo "add capabilities to site"
CAP_BUILD=20090608042922/S-S20090608042922-20090608042922
rsync -rp /shared/webtools/committers/wtpcap-R3.1-S/"${CAP_BUILD}"/updateSite/features/* "${testUpdateSite}"/features/
rsync -rp /shared/webtools/committers/wtpcap-R3.1-S/"${CAP_BUILD}"/updateSite/plugins/* "${testUpdateSite}"/plugins/
rsync -vrp /shared/webtools/committers/wtpcap-R3.1-S/"${CAP_BUILD}"/updateSite/features/* "${testUpdateSite}"/features/
rsync -vrp /shared/webtools/committers/wtpcap-R3.1-S/"${CAP_BUILD}"/updateSite/plugins/* "${testUpdateSite}"/plugins/
echo "add jaxws to site"
JAXWS_BUILD=I-I20090813210640-20090813210640
rsync -rp "${HOME}"/downloads/webtools/downloads/drops/R0.5/"${JAXWS_BUILD}"/updateSite/features/* "${testUpdateSite}"/features/
rsync -rp "${HOME}"/downloads/webtools/downloads/drops/R0.5/"${JAXWS_BUILD}"/updateSite/plugins/* "${testUpdateSite}"/plugins/
rsync -vrp "${HOME}"/downloads/webtools/downloads/drops/R0.5/"${JAXWS_BUILD}"/updateSite/features/* "${testUpdateSite}"/features/
rsync -vrp "${HOME}"/downloads/webtools/downloads/drops/R0.5/"${JAXWS_BUILD}"/updateSite/plugins/* "${testUpdateSite}"/plugins/
./createMirrorFile.sh -s "$stream" -b "${testUpdateSite}"
......
......@@ -21,7 +21,6 @@
<file path="/org.eclipse.wtp.releng.webupdatesite/features-galileo-wtp.xml"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/plugin.properties"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/updateTestUpdateSite.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/webtools.build"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/instructions.txt"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/updateGanymedeMirrorPatches.xml"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/createP2Repo.xml"/>
......@@ -31,17 +30,15 @@
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/getWTPUpdateToolsFromCVS.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/copyToFinalUpdateSite-siteFiles.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/updateMirrorProject.xml"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/copyToMilestoneDirectory-SiteFiles.sh"/>
<folder path="/org.eclipse.wtp.releng.webupdatesite/META-INF"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/copyToMilestoneDirectory-SiteFiles.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/createMirrorSite.xml"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/properties.shsource"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/updateGanymedeMirrorAll.xml"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/ant.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/createMirrorFile.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/runUpdateAllProjects.sh"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/siteFileUpdaterManifest.mf"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/.project"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/wtp.sc"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build-home/updateGalileoMirrorAll.xml"/>
<file path="/org.eclipse.wtp.releng.webupdatesite/build.properties"/>
</selectedElements>
......
......@@ -147,7 +147,7 @@ public class CreateFeatureUpdateFile {
try {
Document newDOM = updateFeatureDOM(siteDOM, currentFeatureVersions);
Document newDOM = updateSiteFeatureDOM(siteDOM, currentFeatureVersions);
// we'll write over what we read it
outfile = new FileOutputStream(sitexmlFileName);
......@@ -164,6 +164,40 @@ public class CreateFeatureUpdateFile {
}
private Document updateSiteFeatureDOM(Document siteDOM, Map currentFeatureVersions) {
NodeList features = siteDOM.getElementsByTagName("feature");
for (int i = 0; i < features.getLength(); i++) {
Node featureElement = features.item(i);
NamedNodeMap attributes = featureElement.getAttributes();
Node featureURLNode = attributes.getNamedItem("url");
String featureURL = featureURLNode.getNodeValue();
Node featureIDNode = attributes.getNamedItem("id");
String featureID = featureIDNode.getNodeValue();
Node featureVersionNode = attributes.getNamedItem("version");
String featureVersion = featureVersionNode.getNodeValue();
// check if still has substitutable value
if (featureVersion.equals("${"+featureID+"}")) {
String currentVersion = (String) currentFeatureVersions.get(featureID);
System.out.println("Substitutable value found: ");
System.out.println(" " + featureID);
System.out.println(" " + currentVersion);
featureVersionNode.setNodeValue(currentVersion);
String newfeatureURL = featureURL.replace("${"+featureID+"}", currentVersion);
featureURLNode.setNodeValue(newfeatureURL);
}
}
return siteDOM;
}
private void doList(String[] featureDirectories, String[] featureOfFocus, String filename) throws IOException {
File outFile = new File(filename);
Writer output = new FileWriter(outFile);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment