Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: In versions 3.0+, make search for recipes case-insensitive again (or selectable by user?) #919

Open
workflowsguy opened this issue Dec 14, 2023 · 4 comments
Assignees
Labels
beta Only for AutoPkg beta releases

Comments

@workflowsguy
Copy link

THIS IS ONLY INTENDED FOR AUTOPKG BETAS.

Describe the problem
In AutoPkr 3.0RC2, searching for recipe names is now case-sensitive, whereas it was case-insensitive in 2.x.
I initially tripped over this when I was "reusing" autopkg commands from the shell's history that had the recipe names in lower case, which after running for quite some time, caused the search to fail (but gave a suggestion for the correct spelling, which I overlooked...).

Expected behavior
As there are pros and cons for both keeping and changing the behaviour, @nmcspadden has suggested opening an enhancement request for a discussion about this.

I don't know what the default behaviour could be, but maybe there could be a preference setting that can be set by the user and overriden through a command line argument?

Version (please complete the following information):

  • OS version: -
  • AutoPkg Version: 3.0+
@gregneagle
Copy link
Contributor

I think it's certainly reasonable for a search intended to be consumed by humans to be case-insensitive. If I search for "GoogleChrome" I probably want to see "googlechrome" as a match.
It's less clear how this behavior should be for, say, an autopkg run of a list of recipes. If that list contains

GoogleChrome.munki

But there are "GoogleChrome.munki.recipe" and "googlechrome.munki.recipe" recipes in the search paths, and "googlechrome.munki.recipe" is actually higher in the search path, should autopkg run that? What is the current behavior? Is this behavior what a human might expect?

@gregneagle
Copy link
Contributor

Some of the ambiguity and possibly unexpected behavior here (and elsewhere!) might possibly be addressed by having autopkg run by default only find and run recipes from the RecipeOverrides directory. It would then require a special flag to have it search outside the overrides...

@nmcspadden
Copy link
Contributor

nmcspadden commented Dec 14, 2023 via email

@gregneagle
Copy link
Contributor

With overrides this sort of naming conflict is far less likely, since by default all overrides are stored in a single directory.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beta Only for AutoPkg beta releases
Projects
None yet
Development

No branches or pull requests

3 participants