# Uninstall.ps1 # Script to uninstall the folder backup context menu integration # Check for admin rights $isAdmin = ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator) if (-not $isAdmin) { Write-Host "Bu komut dosyası yönetici ayrıcalıkları gerektirir. Lütfen Yönetici olarak çalıştırın." -ForegroundColor Red exit 1 } Write-Host "Klasör Yedekleme Sağ Tık Menüsü Entegrasyonu Kaldırılıyor..." -ForegroundColor Yellow # Define registry paths $FolderContextMenuPath = "Registry::HKEY_CLASSES_ROOT\Directory\shell\BackupFolder" $BackgroundContextMenuPath = "Registry::HKEY_CLASSES_ROOT\Directory\Background\shell\BackupFolder" try { # Remove folder context menu entry if (Test-Path $FolderContextMenuPath) { Remove-Item -Path $FolderContextMenuPath -Recurse -Force Write-Host "Klasör sağ tık menüsü girdisi kaldırıldı" -ForegroundColor Green } # Remove background context menu entry if (Test-Path $BackgroundContextMenuPath) { Remove-Item -Path $BackgroundContextMenuPath -Recurse -Force Write-Host "Arka plan sağ tık menüsü girdisi kaldırıldı" -ForegroundColor Green } Write-Host "Kaldırma işlemi başarıyla tamamlandı!" -ForegroundColor Green } catch { Write-Host "Kaldırma işlemi sırasında hata oluştu: $($_.Exception.Message)" -ForegroundColor Red }