From ceeefae7d0118732399e7d7f738d3e2e18ad30d5 Mon Sep 17 00:00:00 2001 From: 10sr <8slashes+git@gmail.com> Date: Wed, 10 Oct 2012 15:00:28 +0900 Subject: [PATCH] newline can be expressed using $ --- bashrc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bashrc b/bashrc index e814710..87af4d0 100755 --- a/bashrc +++ b/bashrc @@ -247,8 +247,7 @@ __dirs_rm_dup(){ for d in "$@" do local next="$(__realpath --strip "$d")" - for l in $(\dirs -v -l | cut -d " -" -f 2- | \grep -x " *[0-9]\+ \+${next}" | \grep -o "^ *[0-9]\+ " | tac) + for l in $(\dirs -v -l | cut -d $'\n' -f 2- | \grep -x " *[0-9]\+ \+${next}" | \grep -o "^ *[0-9]\+ " | tac) do popd +$l -n >/dev/null done