[xml]$xml_with = Get-Content Z:\keys.with.xml
[xml]$xml_without = Get-Content Z:\keys.without.xml
$phrases_with = $xml_with.SelectNodes("/sitecore/phrase")
$phrases_without = $xml_without.SelectNodes("/sitecore/phrase")
foreach ($phrase_with in $phrases_with) {
foreach ($phrase_without in $phrases_without) {
if ($phrase_with.GetAttribute("key") -eq $phrase_without.GetAttribute("key")) {
$phrase_with.ParentNode.RemoveChild($phrase_with)
break
}
}
}
$xml_with.Save("Z:\keys.diff.xml")