PSColor
PSColor copied to clipboard
Cannot load module on PowerShell Core 6.2.3 on Ubuntu
This should speak for itself:
> $PSVersionTable
Name Value
---- -----
PSVersion 6.2.3
PSEdition Core
GitCommitId 6.2.3
OS Linux 4.15.0-72-generic #81-Ubuntu SMP Tue Nov 26 12:20:02 UTC 2019
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
> import-module -Verbose PSColor
VERBOSE: Skipping the Version folder 1.0.0.0 under Module /home/sto/.local/share/powershell/Modules/PSColor as it does not have a valid module manifest file.
import-module : The specified module 'PSColor' was not loaded because no valid module file was found in any module directory.
At line:1 char:1
+ import-module -Verbose PSColor
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ResourceUnavailable: (PSColor:String) [Import-Module], FileNotFoundException
+ FullyQualifiedErrorId : Modules_ModuleNotFound,Microsoft.PowerShell.Commands.ImportModuleCommand
> ls -l /home/sto/.local/share/powershell/Modules/PSColor/1.0.0.0/
total 48
-rw-rw-r-- 1 sto sto 2879 Mar 2 2016 FileInfo.ps1
-rw-rw-r-- 1 sto sto 560 Mar 2 2016 MatchInfo.ps1
-rw-rw-r-- 1 sto sto 1065 Mar 2 2016 ProcessInfo.ps1
-rw-rw-r-- 1 sto sto 11259 Mar 2 2016 PSColorHelper.ps1
-rw-rw-r-- 1 sto sto 5306 Mar 2 2016 PsColor.psd1
-rw-rw-r-- 1 sto sto 1702 Mar 2 2016 PSColor.psm1
-rw-rw-r-- 1 sto sto 6174 Dec 24 09:53 PSGetModuleInfo.xml
-rw-rw-r-- 1 sto sto 960 Mar 2 2016 ServiceController.ps1
Just in case it doesnt speak for itself; the file PsColor.psd1
has a lowercase s
and renaming the file to PSColor.psd1
fixes it.
Indeed! Shame on me for not detecting that when pasting the ls -l
output...
At least, the fix to be included in the next release is an easy one. I might even try to find some bandwidth to create the corresponding PR...
I run into the same problem