added plugin
parent
1293dbf086
commit
92dce20e3c
|
|
@ -0,0 +1,17 @@
|
||||||
|
cite about-plugin
|
||||||
|
about-plugin 'cdup - traverse parent directories with ease. inspired by a script from tyskby'
|
||||||
|
|
||||||
|
cdup() {
|
||||||
|
if [[ $1 =~ .{2,} ]]; then
|
||||||
|
local count
|
||||||
|
|
||||||
|
count=${1:1}
|
||||||
|
|
||||||
|
for ((i=1; i<=${#count}; i++)); do
|
||||||
|
cd ..
|
||||||
|
done
|
||||||
|
|
||||||
|
pwd
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
Loading…
Reference in New Issue