Files
claudetools/clients/cascades-tucson/scripts/debug-gpp-shortcuts.ps1
Howard Enos 8d2ca14cac sync: auto-sync from HOWARD-HOME at 2026-07-17 14:14:41
Author: Howard Enos
Machine: HOWARD-HOME
Timestamp: 2026-07-17 14:14:41
2026-07-17 14:15:20 -07:00

15 lines
805 B
PowerShell

# Run as the logged-in user to see what GPOs apply to THEM
Write-Output "=== Who am I ==="
whoami
Write-Output ""
Write-Output "=== User GPO results ==="
gpresult /scope user /r 2>&1
Write-Output ""
Write-Output "=== User desktop contents ==="
$desk = [Environment]::GetFolderPath("Desktop")
Write-Output "Desktop path: $desk"
Get-ChildItem "$desk\*" -ErrorAction SilentlyContinue | ForEach-Object { Write-Output " $($_.Name)" }
Write-Output ""
Write-Output "=== Event log: GP Preferences ==="
Get-WinEvent -LogName "Microsoft-Windows-GroupPolicy/Operational" -MaxEvents 20 -ErrorAction SilentlyContinue | Where-Object { $_.Message -match 'Shortcut|Preference|CSE|Extension' } | ForEach-Object { Write-Output "$($_.TimeCreated) [$($_.Id)] $($_.Message.Substring(0,[Math]::Min(200,$_.Message.Length)))" }