Open Yapper27 opened 1 week ago
Were you following this guide???
Customize & Beautify Your Windows Terminal (2022 Edition)
In the article, they used the following command:
Install-Script -Name pwshfetch-test-1
If you open the pwshfetch-test-1.ps1
file located in C:\Program Files\WindowsPowerShell\Scripts
, you’ll notice that they used a deprecated feature, clist
.
Here's an excerpt from the script:
if ("choco" -in $ShowPkgs -and (Get-Command -Name choco -ErrorAction Ignore)) {
$chocopkg = (& clist -l)[-1].Split(' ')[0] - 1
if ($chocopkg) {
$pkgs += "$chocopkg (choco)"
}
}
You can resolve this by either installing the latest version or simply replacing clist
with choco list -l
in the script. This worked for me.
& : The term 'clist' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At C:\Program Files\WindowsPowerShell\Scripts\pwshfetch-test-1.ps1:843 char:24