Force shallow-tap

I see with https://github.com/Homebrew/brew/pull/6991 and https://github.com/Homebrew/brew/pull/7053 that homebrew no longer does shallow clones for taps. (cool!)

The wording of the docs state that full clones are the default; which (to me, at least) implies that it is possible to instruct brew to do a shallow clone if desired. (ie, for CI)

I’ve tried tapping with --full=false and --no-full, both causing errors (needless argument and invalid option, respectively).

Is there still a mechanism to force homebrew to do a shallow clone for taps? I understand for common usage, shallow is no longer desirable. But for CI, shallow would still be preferred, as the tap will only ever be fetched once.

I also understand that I could do that git-clone manually. However, my use-case is for creating a setup-homebrew GitHub Action which takes an optional list of taps. As I’m not in control of the format of these tap names, (they could be short name, full name, or potentially even full URLs), doing a manual git-clone means my action would need to duplicate Homebrew’s tap name normalization logic. Duplicating that logic would be error prone, and I’d rather not introduce the possibility of drift between Homebrew’s tapname logic and my action’s logic.

If it’s not possible to force a shallow clone through the CLI, would that option be desired? Alternatively, are there any homebrew helpers for the tap name expansion that would minimize the risk of errors if I were to duplicate that logic? (FWIW, the action is a JS Action, though I suppose I could invoke brew ruby to print the expanded tap name… :thinking:)

Yes, I think so given the example you’ve suggested, thanks!