1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-11-25 15:20:08 +00:00

fix(common-aliases)!: don't overshadow fd if installed (#9162)

BREAKING CHANGE: in `common-aliases`, the `fd` alias won't be defined if `fd` is installed (https://github.com/sharkdp/fd).
This commit is contained in:
Marc Cornellà 2020-12-09 23:17:53 +01:00 committed by GitHub
commit e4082a951f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View file

@ -40,11 +40,13 @@ plugins=(... common-aliases)
| Alias | Command | Description | | Alias | Command | Description |
|-------|-----------------------------------------------------|-----------------------------------------| |-------|-----------------------------------------------------|-----------------------------------------|
| fd | `find . -type d -name` | Find a directory with the given name | | fd\* | `find . -type d -name` | Find a directory with the given name |
| ff | `find . -type f -name` | Find a file with the given name | | ff | `find . -type f -name` | Find a file with the given name |
| grep | `grep --color` | Searches for a query string | | grep | `grep --color` | Searches for a query string |
| sgrep | `grep -R -n -H -C 5 --exclude-dir={.git,.svn,CVS}` | Useful for searching within files | | sgrep | `grep -R -n -H -C 5 --exclude-dir={.git,.svn,CVS}` | Useful for searching within files |
\* Only if the [`fd`](https://github.com/sharkdp/fd) command isn't installed.
### Other Aliases ### Other Aliases
| Alias | Command | Description | | Alias | Command | Description |

View file

@ -34,7 +34,7 @@ alias -g P="2>&1| pygmentize -l pytb"
alias dud='du -d 1 -h' alias dud='du -d 1 -h'
alias duf='du -sh *' alias duf='du -sh *'
alias fd='find . -type d -name' (( $+commands[fd] )) || alias fd='find . -type d -name'
alias ff='find . -type f -name' alias ff='find . -type f -name'
alias h='history' alias h='history'