- Open a PS shell
- In the shell type $profile and then press Enter. This shows you the path to the profile file.
- Create the profile file. Type: new-item -path $profile -itemtype file -force
- In your new profile file enter a line like the following which is a shortcut for editing you new profile file: function pro { notepad $profile }
- Next enable execution of PowerShell scripts. Per default you cannot execute PowerShell scripts. Enabling scripts can be done with the following command: set-executionpolicy remotesigned. Under Vista this will only work if you run the PowerShell as an administrator.
- Open a new PowerShell and test your new function added previously: pro
Learned bias interferes with reasoning
8 months ago