Giter Site home page Giter Site logo

Search problem about chocolateyget HOT 10 CLOSED

jianyunt avatar jianyunt commented on June 17, 2024
Search problem

from chocolateyget.

Comments (10)

jianyunt avatar jianyunt commented on June 17, 2024

@ferventcoder, any ideas what's going on for the packages in https://chocolatey.org/? I cannot find or install.

PS C:\test> choco search nodejs --id-starts-with
Chocolatey v0.10.8
0 packages found.
PS C:\test> choco search 7zip
Chocolatey v0.10.8
0 packages found.
PS C:\test> choco list chrome*
Chocolatey v0.10.8
0 packages found.
PS C:\test> clist *chrome*
Chocolatey v0.10.8
0 packages found.

PS C:\> choco install 7zip
Chocolatey v0.10.8
Installing the following packages:
7zip
By installing you accept licenses for the packages.
7zip not installed. The package was not found with the source(s) listed.
 If you specified a particular version and are receiving this message, it is possible that the packa
 Version: ""
 Source(s): "http://wanuget/bootstrap/nuget"

Chocolatey installed 0/1 packages. 1 packages failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).

from chocolateyget.

ferventcoder avatar ferventcoder commented on June 17, 2024

@jianyunt looks like maybe the source for you.

Source(s): "http://wanuget/bootstrap/nuget"

from chocolateyget.

jianyunt avatar jianyunt commented on June 17, 2024

@ferventcoder no luck with the source. what's the syntax?

PS C:\Program Files\7-Zip> choco search 7zip -s "'http://wanuget/bootstrap/nuget'"
Chocolatey v0.10.8
0 packages found.
PS C:\Program Files\7-Zip> choco search nodejs -s "http://wanuget/bootstrap/nuget"
Chocolatey v0.10.8
0 packages found.

from chocolateyget.

ferventcoder avatar ferventcoder commented on June 17, 2024

I don't know that source, I'm thinking it might be something local for you?

from chocolateyget.

ferventcoder avatar ferventcoder commented on June 17, 2024

You have the syntax right, but if you don't have those packages on the source you are using, it won't turn up results. The community repo is at https://chocolatey.org/api/v2

from chocolateyget.

jianyunt avatar jianyunt commented on June 17, 2024

@sixtead it looks like working now
Find-Package -Name GoogleChrome -ProviderName ChocolateyGet
or
Find-Package -Name *Chrome -ProviderName ChocolateyGet

PS Azure:\> Find-Package -Name GoogleChrome  -ProviderName ChocolateyGet

Name                           Version          Source           Summary
----                           -------          ------           -------
GoogleChrome                   63.0.3239.132    https://www.c...


Azure:\
PS Azure:\> Find-Package -Name  *Chrome  -ProviderName ChocolateyGet

Name                           Version          Source           Summary
----                           -------          ------           -------
GoogleChrome                   63.0.3239.132    https://www.c...
google-chrome-x64              47.0.2526.81     https://www.c...
adblockpluschrome              1.12.4           https://www.c...
...

from chocolateyget.

sixtead avatar sixtead commented on June 17, 2024

Search works fine. I mean, searching packages with choco works without asterisk (choco list chrome), searching packages with PowerShell using Chocolatey package provider (Find-Package -Name chrome -ProviderName Chocolatey) works without asterisk. But when you search package with ChocolateyGet provider (Find-Package -Name chrome -ProviderName ChocolateyGet) it gives you error.

Maybe it should behave like choco itself (without asterisk)?

And is there a way not ot throw error message and print something like "The package 'chrome' cannot be found, try using Find-Package -Name *chrome -ProviderName ChocolateyGet instead"?

from chocolateyget.

jianyunt avatar jianyunt commented on June 17, 2024

Got it. Thanks @sixtead.
I made the ChocolateyGet search operation as "exact match" so that it works just like PowerShellGet (find-module) for http://PowerShellGallery.com.
As ChocolateyGet has over 320 thousands downloads already I cannot remove 'exact match' behavior otherwise I break someone else. Maybe I can add optional argument later.
To remove the exact match behavior, you may comment out everything in the Test-name and replace them "return true". ChocolateyGet.psm1 file can be found in your module installed folder.

from chocolateyget.

sixtead avatar sixtead commented on June 17, 2024

Ok. Thanks for explaration. I think issue can be closed.

from chocolateyget.

jianyunt avatar jianyunt commented on June 17, 2024

Thanks closed the issue.

from chocolateyget.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.