You may find cmdlets include this module as.....
PS C:\Windows\System32\WindowsPowerShell\v1.0> Get-Command -Module PS-Profile | ft -AutoSize
CommandType Name ModuleName
----------- ---- ----------
Function Backup-PSProfile PS-Profile
Function Edit-PSProfile PS-Profile
Function Get-PSProfile PS-Profile
Function New-PSProfile PS-Profile
Function Remove-PSProfile PS-Profile
Function Test-PSProfile PS-Profile
All PS-Profile Cmndlets offer you common switch for profile path selection.
Put switch for Profile you want to create from below.
-CurrentUserAllHosts : Current user's both PowerShell.exe and PowerShell_ise.exe will be affect.
--CurrentUserCurrentPSHost : Current user's PowerShell.exewill be affect.
--CurrentUserCurrentPSISEHost : Current user's PowerShell_ise.exe will be affect.
-AllUsersAllHosts : All user's both PowerShell.exe and PowerShell_ise.exe will be affect.
-AllUsersCurrentPSHost : All user's both PowerShell.exe will be affect.
-AllUsersCurrentPSISEHost : All user's both PowerShell_ise.exe will be affect.
Cmdlets | Description |
---|---|
Backup-PSProfile | This Cmdlet will backup you profile to backup folder under profile path. |
Edit-PSProfile | If you run with psise, then profile file will on in psise, if not then notepad will open |
Get-PSProfile | This Cmdlet will Get Profile file information. |
New-PSProfile | This Cmdlet will create Profile file. |
Remove-PSProfile | This Cmdlet will remove Profile file. |
Test-PSProfile | This Cmdlet will return bool for profile exist. |
- Create new profile for current users all hosts
New-PSProfile -CurrentUserAllHosts
- Create new profile for all users all hosts
New-PSProfile -AllUsersAllHosts
- Test profile for current users all hosts is exit
Test-PSProfile -CurrentUserAllHosts
- Get profile file information for current users all hosts
Get-PSProfile -CurrentUserAllHosts
- Edit profile for current users all hosts in new psise tab if run will psise, else open notepad.
Test-PSProfile -CurrentUserAllHosts
- Backup profile for current users all hosts
- Default 3 times retention. (add -retenction to change duration)
Backup-PSProfile -CurrentUserAllHosts
- Remove profile for current users all hosts
Remove-PSProfile -CurrentUserAllHosts