Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save michaellwest/eb60ec5d9a8bf0f4ed077fd64de10713 to your computer and use it in GitHub Desktop.
Save michaellwest/eb60ec5d9a8bf0f4ed077fd64de10713 to your computer and use it in GitHub Desktop.
Queries a list of items that have been modified after a certain date. Generates a CSV and downloads from the server.
$startDate = [datetime]"02/24/2016"
$days = ([datetime]::today - $startDate).Days
Get-ChildItem master:\content\home -Recurse |
? { $_."__updated" -gt (Get-Date).AddDays(-$days) } |
Where-Object { "Resource Reference","Sitemap","AddOns","Market Generic Page" -notcontains $_.TemplateName } |
Select-Object -Property ID, Name, "__updated", "__updated by", "TemplateName" |
Export-Csv -Path "$($SitecoreDataFolder)\page-changes.csv"
Send-File "$($SitecoreDataFolder)\page-changes.csv"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment