powershell-profile
powershell-profile copied to clipboard
Clarification in the documentation regarding what "Edit-Profile" actually does and how it's implimented
After I installed it, I ran into an error because my Document folder is in Dropbox. I see that a recent pull request [fix #133] corrects this error, but in trying to fix it myself, I tried using the "Edit-Profile," command.
Which created a new "profile.ps1" file in my profile folder.
My assumption was that anything I add to profile.ps1 "changes" (aka overrides) what's in PowerShell_profile.ps1 , so I tried adding the line:
$timeFilePath = [Environment]::GetFolderPath("MyDocuments") + "\PowerShell\LastExecutionTime.txt"
...and started a new PowerShell session. It doesn't pick up my change; I still see the same error.
It looks like my assumption of what "changes" means is incorrect.
From what I can deduce, profile.ps1 gets run first, and then PowerShell_profile.ps1 is run, so profile.ps1 is just a way for you to add SEPARATE logic, not a way to override anything in PowerShell_profile.ps1. Is that a correct assumption? The verbiage at the bottom of the main readme could use some clarification to explain this because it's not really about implementing "changes" to PowerShell_profile.ps1 it's about adding additional logic of your own.
Oh, and one more thing: add an image of what it should look like when it's done. I saw fonts installed, but I'm not seeing any font changes that look different from my terminal before the installation.
I generated a pull request to add Override logic that allows profile.ps1 to override variables and functions in PowerShell_profile.ps1.