search/list/find - config setting to control default behavior (by id only vs default of id, description, tags, etc)
A -filter option when using choco list/clist would be wonderful.
i.e. clist -l -filter a* would show only packages beginning with the letter "a."
If there is a current way to achieve the same results directly from choco.exe without such methods as (CMD) | filter "a" (which is not the same as above) than please excuse my ignorance and educate me.
UPDATE: I realize now the -id-starts-with does what I want, but maybe we could get a shortcut alternative argument for it? -isw seems the easy choice but not memorable. -beginswith I like. -name or -match would be nice but intuitively should search for the input in the whole package name not just the beginning.
Ideally a -filter choice that can take a wildcards would be optimal.
minus the switch --filter (and by the way, double dash for anything that is not a single letter / aka short option), this already exists as what you pass to search/list/find.
Hmmmmmm, I learned something. Thanks!
Legend: Bold = desired results
Both of these get me close to want I want:
C:>clist intel -l Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
chocolatey-fastanswers.extension 0.0.2 Firefox 66.0.1 gpu-z 2.18.0 gsmartcontrol 1.1.3 intel-chipset-device-software 10.1.17 intel-dsa 19.2.8.7 intel-me-drivers 1824.12.0.1140 intel-network-drivers-win10 23.5.2 logiccards-chrome 1.0.0.2 screenlogic-connect 5.2.736.0020190130 virtualbox 6.0.4 11 packages installed.
C:>clist vnc -l Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
feedly-chrome 35.0.20170115 vnc-connect 6.4.1 vnc-viewer 6.19.107.20190123 3 packages installed.
Both of these give me what I want:
C:>clist intel -id-starts-with -l Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
intel-chipset-device-software 10.1.17 intel-dsa 19.2.8.7 intel-me-drivers 1824.12.0.1140 intel-network-drivers-win10 23.5.2 4 packages installed.
C:>clist vnc -id-starts-with -l Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
vnc-connect 6.4.1 vnc-viewer 6.19.107.20190123 2 packages installed.
But I'd like to match a keyword to a package name only instead of all it's tags and description; i.e. the following doesn't work and yields too many results:
C:>clist driver -l Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
dell-update 3.0.0 dumo 2.17.3.88 geforce-experience 3.18.0.94 hp-universal-print-driver-pcl 6.7.0.23989 intel-chipset-device-software 10.1.17 intel-dsa 19.2.8.7 intel-me-drivers 1824.12.0.1140 intel-network-drivers-win10 23.5.2 ntlite-free 1.7.4.6790 nvidia-display-driver 419.67 nvidia-display-driver-disable-updates-winconfig 0.0.1 open-visual-traceroute 1.7.1 realtek-hd-audio-driver 2.82.0020181008 sumo 5.8.12.415 WinPcap 4.1.3.20161116 15 packages installed.
C:>clist nvidia Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
geforce-game-ready-driver 419.67 [Approved] nvidia-display-driver 419.67 [Approved] geforce-experience 3.18.0.94 [Approved] ddu 18.0.0.9 [Approved] geforce-game-ready-driver-win10 378.92 [Approved] - Possibly broken geforce-game-ready-driver-win7 378.92 [Approved] - Possibly broken nvidia-profile-inspector 2.1.3.10 [Approved] Downloads cached for licensed users - Possibly broken for FOSS users (due to original download location changes by vendor) disable-nvidia-telemetry 1.1.0.20190306 [Approved] Downloads cached for licensed users OpenHardwareMonitor 0.8.0 [Approved] Downloads cached for licensed users Physx.Legacy 9.13.0604 [Approved] Downloads cached for licensed users gpu-z 2.18.0 [Approved] chocolatey-fastanswers.extension 0.0.2 [Approved] disable-nvidia-telemetry.portable 1.1.0 [Approved] Downloads cached for licensed users xmedia-recode 3.4.5.2 [Approved] hdhomerun-view 2018.09.21 [Approved] Downloads cached for licensed users drivermax 10.12.0.10 [Approved] - Possibly broken brainsimulator 0.6.0 [Approved] Downloads cached for licensed users badaboom-media-converter 2.0.0.128 [Approved] Downloads cached for licensed users nvidia-display-driver-disable-updates-winconfig 0.0.1 [Approved] geforce-experience-disable-updates-winconfig 0.0.1 [Approved] moonlight-qt 0.8.0 [Approved] Downloads cached for licensed users vibrancegui 2.0.0.0 [Approved] Downloads cached for licensed users - Possibly broken for FOSS users (due to original download location changes by vendor) 22 packages found.
The real problem is since Chocolatey Install Day One I've never intuitively expected metadata to be a factor in my search results. I definitely see the benefit of it, I'd just like a simple way to factor it out and have a switch to match package names only.
I know this would be a breaking change: maybe the LIST and SEARCH commands could be separated where the LIST command only searches and matches package names while the SEARCH command searches package names and delves deeper into the metadata to find possible packages of interest.
--nameonly could work. --ignoremetadata could work.
Although I'd love a configuration option to flip the metadata search off by default and a --metadata option to manually include it back in.
Output after using a LIST/SEARCH/FIND command could be updated to say something along the lines of:
"Searching for XXXXX in package names, tags, and description from SOURCE. Use --SOMESWITCH to search package names only."
would make it more clear for users not in the know.
@bcurran3 have you seen the documentation here:
https://chocolatey.org/docs/commands-list
Specifically, the --id-only, --by-id-only, and --by-tag-only options? Seems like some combination of these, along with maybe some of the other ones, would get the information that you want.
@gep13 Using all those options seems to get me my desired output:
S:\dev\GitHub\ChocolateyPackages\intel-graphics-driver>choco list driver --id-only --by-id-only --by-tag-only -l Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
hp-universal-print-driver-pcl intel-me-drivers intel-network-drivers-win10 nvidia-display-driver nvidia-display-driver-disable-updates-winconfig realtek-hd-audio-driver 6 packages installed.
S:\dev\GitHub\ChocolateyPackages\intel-graphics-driver>choco list driver --id-only --by-id-only --by-tag-only Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
selenium-chrome-driver geforce-game-ready-driver selenium-gecko-driver selenium-ie-driver nvidia-display-driver sqlserver-odbcdriver driverbooster selenium-edge-driver selenium-opera-driver drivergenius geforce-game-ready-driver-win10 chromedriver selenium-all-drivers intel-driver-update-utility intel-graphics-driver 15 packages found.
Mind you I've done one pass only, what's displayed above. I haven't checked for any omissions. And no matter how much anyone loves using a CLI, who the hell wants to remember and type all that?
There should be a better/easier/more intuitive way!
EDIT: Tried a check for omissions from the CCR and found discrepancy output:
Chocolatey v0.10.13 2 validations performed. 1 success(es), 1 warning(s), and 0 error(s).
selenium-chrome-driver 73.0.3683.68 [Approved] Downloads cached for licensed users geforce-game-ready-driver 419.67 [Approved] selenium-gecko-driver 0.24.0 [Approved] Downloads cached for licensed users selenium-ie-driver 3.14.0 [Approved] Downloads cached for licensed users nvidia-display-driver 419.67 [Approved] sqlserver-odbcdriver 13.1.4413.46 [Approved] Downloads cached for licensed users driverbooster 6.3.0 [Approved] Downloads cached for licensed users selenium-edge-driver 6.17134.20180630 [Approved] Downloads cached for licensed users selenium-opera-driver 2.42 [Approved] Downloads cached for licensed users drivergenius 19.0.0.139 [Approved] Downloads cached for licensed users - Possibly broken for FOSS users (due to original download location changes by vendor) geforce-game-ready-driver-win10 378.92 [Approved] - Possibly broken chromedriver 73.0.3683.680 [Approved] Downloads cached for licensed users selenium-all-drivers 4.0 [Approved] intel-driver-update-utility 3.1.1.220180112 [Approved] - Possibly broken intel-graphics-driver 25.20.100.6323 [Approved] 15 packages found.
S:\dev\GitHub\ChocolateyPackages\intel-graphics-driver>clist | find "driver" selenium-chrome-driver 73.0.3683.68 [Approved] Downloads cached for licensed users geforce-game-ready-driver 419.67 [Approved] driverbooster 6.3.0 [Approved] Downloads cached for licensed users selenium-gecko-driver 0.24.0 [Approved] Downloads cached for licensed users selenium-ie-driver 3.14.0 [Approved] Downloads cached for licensed users sqlserver-odbcdriver 13.1.4413.46 [Approved] Downloads cached for licensed users nvidia-display-driver 419.67 [Approved] selenium-edge-driver 6.17134.20180630 [Approved] Downloads cached for licensed users selenium-opera-driver 2.42 [Approved] Downloads cached for licensed users geforce-game-ready-driver-win10 378.92 [Approved] - Possibly broken drivergenius 19.0.0.139 [Approved] Downloads cached for licensed users - Possibly broken for FOSS users (due to original download location changes by vendor) selenium-all-drivers 4.0 [Approved] intel-driver-update-utility 3.1.1.220180112 [Approved] - Possibly broken drivermax 10.12.0.10 [Approved] - Possibly broken rutoken-drivers 4.2.5.0 [Approved] Downloads cached for licensed users driverfusion 7.0 [Approved] geforce-game-ready-driver-win7 378.92 [Approved] - Possibly broken intel-graphics-driver 25.20.100.6323 [Approved] realtek-hd-audio-driver 2.82.0020181008 [Approved] intel-network-drivers-win10 23.5.2 [Approved] windowsdriverkit10 10.0.17763 [Approved] Downloads cached for licensed users hp-universal-print-driver-pcl 6.7.0.23989 [Approved] Downloads cached for licensed users driverpacksolution 17.2017.2.22 [Approved] Downloads cached for licensed users - Possibly broken for FOSS users (due to original download location changes by vendor) nunit-extension-nunit-v2-driver 3.7.0 [Approved] snappy-driver-installer 1.0.539.20170422 [Approved] Downloads cached for licensed users driverview 1.47 [Approved] Downloads cached for licensed users hp-universal-print-driver-ps 6.7.0.23989 [Approved] Downloads cached for licensed users ftdi-drivers 2.12.28 [Approved] Downloads cached for licensed users - Possibly broken for FOSS users (due to original download location changes by vendor) doubledriver 4.1 [Approved] snappy-driver-installer-origin 1.0.558 [Approved] installeddriverslist 1.05 [Approved] Downloads cached for licensed users
I've tried a couple combinations but they don't yield the same desired result as above. To be clear, I want to search just package names that include a search term.
So changing the default search to be by id is not something that we'd approach due to the ramifications. However, I think we might be able to add a configuration setting for default search behavior that you could swap to be by id only?
Completely understood and reasonable. A switch to search (within) package ID names only is the core request.