Cleanup-PathEnv

1.0.0

This script helps clean up and optimize Windows PATH environment variables by:
- Removing duplicate entries
- Removing invalid/non-existent paths
- Categorizing and reorganizing paths by type
- Creating backups before making changes
- Providing detailed reporting

Installation Options

Copy and Paste the following command to install this package using PowerShellGet More Info

Install-Script -Name Cleanup-PathEnv -RequiredVersion 1.0.0

Copy and Paste the following command to install this package using Microsoft.PowerShell.PSResourceGet More Info

You can deploy this package directly to Azure Automation. Note that deploying packages with dependencies will deploy all the dependencies to Azure Automation. Learn More

Manually download the .nupkg file to your system's default download location. Note that the file won't be unpacked, and won't include any dependencies. Learn More

Owners

Copyright

Jimmy Briggs | 2025

Package Details

Author(s)

  • Jimmy Briggs

Tags

PowerShell Script

Functions

Write-Log Test-PathValidity Get-NormalizedPath Remove-Duplicates Get-PathCategory Restore-PathFromBackup Export-PathReport

Dependencies

This script has no dependencies.

Release Notes

Initial Release

FileList

Version History

Version Downloads Last updated
2.0.0 7 4/14/2025
1.0.0 (current version) 4 4/14/2025