diff --git a/zshrc b/zshrc index 7f9f82d..7b7abb8 100644 --- a/zshrc +++ b/zshrc @@ -3806,6 +3806,15 @@ if command -v direnv &> /dev/null ; then eval "$(direnv hook zsh)" fi +# Command to search C function definitions, with Linux kernel coding style. +# Example: +# $ fdcfun wait_for_completion +if command -v rg &> /dev/null; then + fdcfun() { + rg -U "$1(.*)\n\{" + } +fi + # add local binaries if [[ -r ~/bin ]]; then PATH=$PATH:~/bin