Contact Info

Crumbtrail » Administration » Powershell » Powershell 1.0 » Import-Alias

Import-Alias - Powershell 1.0 CmdLet

Microsoft Windows PowerShell is a command-line shell and scripting tool based on the Microsoft .NET Framework. It is designed for system administrators, engineers and developers to control and automate the administration of Windows and applications.

More than hundred command-line tools (so called "cmdlets") can be used to perform system administration tasks and Windows Management Instrumentation (WMI). These cmdlets are easy to use, with standard naming conventions and common parameters, and standard tools for piping, sorting, filtering, and formatting data and objects.


Import an alias list from a file


-Path path
        The path to the item {may be piped}
        Wildcards are allowed but they must resolve to a single name.

        Pass the object created by Import-Alias through the pipeline.

   -scope string
       The scope to apply to the imported aliases.
       Valid values are "Global", "Local", or "Script", or a number relative
       to the current scope ( 0 through the number of scopes, where 0 is the
       current scope and 1 is its parent). "Local" is the default.
       For more, type "get-help about_scope".

       Allows importing/overwriting an alias that is already defined and has
       the read-only option set. For currently-defined aliases see:
         get-alias | select-object name,Options

       Describe what would happen if you executed the command without actually
       executing the command.

       Prompt for confirmation before executing the command.

       -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutVariable.

Import alias info from SS64.txt:

PS C:\>import-alias SS64.txt