BTS

Message789

Author mika
Recipients ft, gebi
Date 2007-09-13.12:43:22
Content
* Michael Gebetsroither <bts@bts.grml.org> [20070913 13:32]:

> % which d
> d: aliased to dirs -v

Huh?!

# jump between directories
# Copyright 2005 Nikolai Weibull <nikolai@bitwi.se>
# notice: option AUTO_PUSHD has to be set
  #f5# Jump between directories
  d(){
    emulate -L zsh
    autoload -U colors
    local color=$fg_bold[blue]
    integer i=0
    dirs -p | while read dir; do
      local num="${$(printf "%-4d " $i)/ /.}"
      printf " %s  $color%s$reset_color\n" $num $dir
      (( i++ ))
    done
    integer dir=-1
    read -r 'dir?Jump to directory: ' || return
    (( dir == -1 )) && return
    if (( dir < 0 || dir >= i )); then
      echo d: no such directory stack entry: $dir
      return 1
    fi
    cd ~$dir
  }

-> Are you sure you don't have that stuff inside your personal
configuration (outside of grml's zsh configuration) - overriding
grml's d()-function?

regards,
-mika-
History
Date User Action Args
2007-09-13 12:43:23mikasetrecipients: + gebi
2007-09-13 12:43:23mikalinkissue286 messages
2007-09-13 12:43:22mikacreate