Question WRT Powershell ISE on Windows 10 pro. I recently noticed that when I start powershell ISE, I get an error: "The term 'set-variable' is not recognized as the name of a cmdlet......."
However, if I type set-variable once the powershell prompt shows up, it gives me the usual "Supply values for the following parameters:".....
I have also noticed that modules don't seem to 'autoload' anymore. I am manually having to do an import-module these data for things that use to work fine.
So figuring something is fouled up with my profile, I went to edit my profile only to notice $profile doesn't have a value in ISE. So I am wondering if that error I am seeing when ISE starts is it failing to set the value of $profile initially. (Is there any way to trace this?)
I am not sure of any way to 'repair' powershell ISE and am somewhat stuck as to why it can't find set-variable on start up, which is the reason (I think) that $profile is blank
Version info (it seems to set this properly):
C:\WINDOWS\system32> $PSVersionTable Name Value
PSVersion 5.1.19041.1
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.19041.1
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
PSHome value: C:\WINDOWS\system32> $PSHOME C:\Windows\System32\WindowsPowerShell\v1.0
$env:PSModulePath value: C:\WINDOWS\system32> $env:PSModulePath C:\Users\craig\OneDrive - Red Dog Systems\Documents\WindowsPowerShell\Modules;C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules
-- All paths in the above exist.
I am hoping someone out there might have some suggestions on how to sort out what is going on?
Thanks in advance..
cmb..