X-Git-Url: https://git.grml.org/?a=blobdiff_plain;f=etc%2Fzsh%2Fzshrc;h=577c63f094b0ea96a513dfe37d836e0b8e5cbaa3;hb=c9726efc0f6baf5cc1b0144eb6a2b7f5b963e8a0;hp=3f53ec3e4f663b942a1cd36381445ed875c676a9;hpb=01b9ed02a2e39dd58de3bff8a673ac1add3e7bae;p=grml-etc-core.git diff --git a/etc/zsh/zshrc b/etc/zsh/zshrc index 3f53ec3..577c63f 100644 --- a/etc/zsh/zshrc +++ b/etc/zsh/zshrc @@ -3514,17 +3514,25 @@ regcheck() { pcre_match $2 && echo "regex matches" || echo "regex does not match" } +#f5# List files which have been accessed within the last {\it n} days, {\it n} defaults to 1 +accessed() { + emulate -L zsh + print -l -- *(a-${1:-1}) +} + #f5# List files which have been changed within the last {\it n} days, {\it n} defaults to 1 changed() { emulate -L zsh - print -l *(c-${1:-1}) + print -l -- *(c-${1:-1}) } #f5# List files which have been modified within the last {\it n} days, {\it n} defaults to 1 -new() { +modified() { emulate -L zsh - print -l *(m-${1:-1}) + print -l -- *(m-${1:-1}) } +# modified() was named new() in earlier versions, add an alias for backwards compatibility +check_com new || alias new=modified #f5# Grep in history greph() {