Scenario/Problem: You have scripts within a local folder which you want PowerShell to recognize such that you do not need to use the full path name.
Solution: Add the local directory path to the PSModulePath variable.
You add the local folder’s path to the PSModule
environment variable by entering the following command in the PowerShell command prompt (substituting <folder path>
with the local directory path), as shown in Listing 2.2.
$env:PSModulePath = $env:PSModulePath + ";c:<folder path>"
Tip
Add the same exact command line into the PowerShell profile configuration file to always have your local folder added to the PSModulePath. See http://technet.microsoft.com/en-us/library/dd315342.aspx for more information about PowerShell profiles.
18.225.35.81