Created
May 2, 2024 21:30
-
-
Save apandrade/1d79ff996ab51cd7e785c9690f0cc3b1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$rootPath = ""master:/sitecore/content/SiteRoot" | |
Write-Host "Root Path: $($rootPath)" | |
Get-ChildItem -Path $rootPath -Recurse | Foreach-Object{ | |
$id = $_.ID | |
$item = Get-Item -Path master: -ID $id | |
Write-Host "Checking item $($item.Name)-$($id)" | |
Get-ChildItem -Path $item.Parent.Paths.FullPath | Where-Object{ $_.ID.Guid -ne $id.Guid -and $_.Name -eq $item.Name } | Foreach-Object { | |
Write-Host "DUPLICATED - $($_.Paths.FullPath) - $($_.ID.Guid.ToString())" | |
} | |
} | |
Write-Host "All Done..." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment