private void processProjectDependencies(XmlDocument projectDocument, XmlNamespaceManager xmlNamespaceManager)
{
// simply append project postfix to all projects from which this project depends.
// in future we can replace this implementation to more general (at least append only processed projects)
foreach (XmlNode xnode in projectDocument.SelectNodes("/prj:Project/prj:ItemGroup/prj:ProjectReference", xmlNamespaceManager))
{
XmlAttribute includeAttribute = xnode.Attributes["Include"];
if (includeAttribute == null)
continue;
foreach (string extension in new string[2] { ".csproj", ".vbproj" })
{
string includeValue = includeAttribute.Value;
if (includeValue.EndsWith(extension))
{
string projectName = Path.GetFileName(includeValue);
string resultProjectName = processProjectName(projectName);
includeAttribute.Value = includeValue.Replace(projectName, resultProjectName);
}
}
}
}