Overwriting Pre-Defined Aliases

by Feb 12, 2010

PowerShell protects its own pre-defined aliases so you normally cannot override and redefine them. It will still work if you use the correct parameters:

Set-Alias ise notepad -force -Option AllScope

This illustrates that aliases are really only for your convenience in an interactive environment that you control. However, you should never use them in scripts that are designed to run on other systems.

Twitter This Tip! ReTweet this Tip!