问题
I am looking at my $profile variable and I see that it is pointing to C:\users\username\Documents\windowsPowershell\Microsoft.Powershell_profile.ps1
However, when I attempt to browse to this directory I cannot find the folder/directory named WindowsPowerShell that is supposed to be in the documents folder. Any ideas?
I was hoping I could set a permanent path that is linked to my profile or at least loaded with it when Powershell is loaded. Am I on the right track here?
thanks!
-Dustin
回答1:
What you see for the path is right. It is the path for your user profile (for the console host) and it is normal to not see the folder and the file. You can create it and start using your profile - new-item -type file -path $profile -force
See here for more: http://technet.microsoft.com/en-us/library/dd315342.aspx
来源:https://stackoverflow.com/questions/8997316/powershell-profile-is-pointing-to-a-path-that-i-cant-find-and-setting-permane