I would like to write a git alias for:
git log --all --grep='Big boi'
What I have so far is:
[alias]
search = "!f() { str=${@}; echo $str; git log --all --grep=$str; }; f"
Which echos the string perfectly fine but gives an error, I can't seem to figure out how to pass the string to the grep flag.
$ user in ~/src/repo on master λ git search 'Big boi'
Big boi
fatal: ambiguous argument 'boi': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
I'm using zsh if it makes any difference . . .