Forum Discussion
How to change remote session prompt?
For my 7.4.1 Powershell, I have a custom prompt stored in $PROFILE\profile.ps1 (that's the only profile file that exists on my machine). This works well until I start a remote session using Enter-PSSession, where I get a default prompt. How can I apply my custom prompt to remote sessions as well?
- LainRobertsonSilver Contributor
Hi, Andreas.
Have you tried the first option for "All users, All hosts"? There's a number of different locations for profile customisations for both PowerShell and Windows PowerShell.
If a particular file doesn't yet exist, create it.
Cheers,
Lain
- ahinterlCopper ContributorYes, I have. My profile is in the all users/all hosts location (see initial post) as per Microsoft's docs. I don't use Windows PowerShell as written (forgot to say that I run PowerShell on Windows 11).
- LainRobertsonSilver Contributor
Okay, my fault.
Perhaps I misread your original post, as I noted you had used $PROFILE, not $PSHOME.
But if you have indeed tried both "all hosts" options, then I have nothing more to add at this stage.
Cheers,
Lain