3 ms·
On what shell? That doesn't work in bash. I use `type` for that, since it'll tell you if it's on PATH, a function, or an alias which gdb /opt/homebrew/bin/gdb
by Graziano_M 2y ago
On what shell? That doesn't work in bash. I use `type` for that, since it'll tell you if it's on PATH, a function, or an alias
which gdb
/opt/homebrew/bin/gdb
~
type gdb
gdb is aliased to `gdb -q'
- lvncelot 2y agozsh for me ~ ▸ which k k: aliased to kubectl
- pcthrowaway 2y agoIn bash this is how I get git completions working (with bash functions rather than aliases): __git_complete grm _git_rm grm() { git rm "${@}" } Internally git uses the __git_complete function to set up completions for its subcommands, though this may be specific to your OS/distro and perhaps or git version. This does seem to ship as part of git now, here[1]. [1]: https://github.com/git/git/blob/6a64ac7b014fa2cfa7a69af3c253bcd53a94b428/contrib/completion/git-completion.bash#L3958 https://github.com/git/git/blob/6a64ac7b014fa2cfa7a69af3c253...