Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Gary Ewan Park
@gep13
I don’t know what that means, sorry.
Starz0r
@Starz0r
I was talking about the Write-Warning, but it that doesn't mean anything because it's just iterating through the list
Looks like Test-Path is failing see that item as a folder?
Gary Ewan Park
@gep13
Yes, that is my assumption at this point.
Starz0r
@Starz0r
I'm not really sure how, since it literally is the type it's looking for
What happens if you Write-Warning the Test-Path check?
Starz0r
@Starz0r
Tried it myself, it just writes false for all entries
Gary Ewan Park
@gep13
@Starz0r try the following...
# cleanup
ForEach ($Installation in $PrevInstallations) {
    if ($Installation.PSIsContainer) {
        Remove-Item -Recurse $Installation.FullName
    };
};
Remove-Item ($ToolsPath + '\*.' + 'zip');
Notice the usage of PSIsContainer, and also the usage of .FullName
Otherwise, the attempt to delete the directory usages a relative path, which likey won't exist
This didn't show up until I remove the -EA 0
Once you know this is working as you expect it to, you can add that back in again
The relative path might actually explain why the Test-Path didn't work
Gary Ewan Park
@gep13
Yip, this was the issue. Using this works:
# cleanup
ForEach ($Installation in $PrevInstallations) {
    if (Test-Path -Path $Installation.FullName -PathType Container) {
        Remove-Item -Recurse -Force $Installation.FullName;
    };
};
Remove-Item ($ToolsPath + '\*.' + 'zip');
Again, you can add the EA back in, once you have tested things out.
@Starz0r ^^
Starz0r
@Starz0r
@gep13 As soon as you posted the first snippet I went to go check it out
When I realized it worked, I went to see if it was also the .FullName suffix that fixed it, and of course it was
Not sure why, since I thought scripts were executed in the tools folder, so how this could be a problem is beyond me
Thank you so much for the help
millengineerschicago
@millengineerschicago
Hello all, is this the right place to ask about being unblocked from doing too many requests?
Wencey Wang
@WenceyWang
Hello there, I am wondering that if there's a person reading security@chocolatey.io? Or what else should I do to inform a security issue?
2 replies
Zafer Balkan
@zbalkan
Hello everyone. I just wanted to ask if the chocolatey.lib library is released for internal use. Because I used it recently, it worked really well except for a condition. But I do not know if it's possible to open an issue on the library itself as it is not documented.
Gary Ewan Park
@gep13
@zbalkan the chocolatey.lib nuget package comes from the chocolatey/choco GitHub repository, so if there is a problem with it, you would create an issue over there.
Zafer Balkan
@zbalkan
@gep13 Thank you. I'll create the issue with the required information.
Glenn Carr
@glenncarr
I use choco upgrade all frequently and all the apps I currently want to upgrade are the default version (64bit or 32bit) apps, EXCEPT for the 32-bit version of notepad++ - is there a way to call upgrade all and have it upgrade all apps, including the 32-bit versions of apps?
4 replies
Gabriel Ribeiro (K0media)
@K0media

I think I'm skipping something, but...

Is there a command as choco run firefox or crun firefox directly via CLI?

I think that would be nice in case the packages aren't being listed under start menu or PowerToys, for example.

It usually happens to do not have the packages listed when they don't come with the .install arguments.

I'll send an example soon.

image.png
image.png
Gabriel Ribeiro (K0media)
@K0media
image.png
TheCakeIsNaOH
@thecakeisnaoh:naoh.host
[m]
This is the important line to pay attention too:
Shimgen has successfully created a shim for dukto.exe
Try running dukto in cmd/powershell.
Christopher
@metc
Hello everyone. I would like to group the packages/software I use with choco into groups, like for instance "Utility software", "Programming software", "Photo editors", etc.
My goal would be to install all packages from a group with a single command. I would like to tag or group the packages I use often into groups, so I could install a list of packages with a single command.
How could I achieve this? Is there a feature like this in choco? Thank you.
2 replies
Paul Broadwith
@pauby
@/all Get all Chocolatey this #Hacktoberfest and plant a tree or earn yourself a t-shirt! https://blog.chocolatey.org/2021/10/hacktoberfest2021/
Etienne Laurin
@AtnNn
Hello! Is there a good way to find upgradable packages from a packages.config without installing them?
5 replies
Gabriel Ribeiro (K0media)
@K0media

Try running dukto in cmd/powershell.

I think I forgot about the most obvious thing, lol.

Thanks for the reminder. I'm quite a layman in terms of scripting and CLI, sorry.

liangliangii
@liangliangii
ERROR: The term 'C:\ProgramData\chocolatey\helpers\chocolateyScriptRunner.ps1' 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.
image.png
liangliangii
@liangliangii
Save the children~
liangliangii
@liangliangii
resolved~
Gary Ewan Park
@gep13
@liangliangii what did you do to resolve this issue?
liangliangii
@liangliangii
Change powershell language model
Gary Ewan Park
@gep13
@liangliangii can you elaborate on this? What exactly did you have to do?
Laszlo Pinter
@pinterl
I have a valid enterprise license and want to internalize packages. I have choco and the extensions installed, license found by choco. When I try "choco downlad" I get the error message: Could not find a command registered that meets 'download'. What is C4B and is it a separate installer?
9 replies
Paul Broadwith
@pauby
@/all We are moving to Discord for our Community! More details to follow. Join us at https://ch0.co/community and https://ch0.co/community-support!
jyanga
@jyanga
hello...i am still new to Chocolatey. I encountered the error Too Many Requests in my attempt to install git on 6 test machines programmatically. help.
jyanga
@jyanga
@gep13 thanks...i shall read it now
Firehawke
@firehawke:matrix.org
[m]
Hmm. I have a question, but if you're moving to Discord I might as well wait the 10 minutes before I can type it there.