浏览代码
Simplify argument handling
master
Arun Prakash Jana
7 年前
找不到此签名对应的密钥
GPG 密钥 ID: A75979F35C080412
共有
3 个文件被更改,包括
3 次插入 和
11 次删除
-
misc/quitcd/quitcd.bash
-
misc/quitcd/quitcd.fish
-
misc/quitcd/quitcd.zsh
|
|
@@ -2,11 +2,7 @@ export NNN_TMPFILE="/tmp/nnn" |
|
|
|
|
|
|
|
n() |
|
|
|
{ |
|
|
|
if [ -n "$1" ]; then |
|
|
|
nnn "$1" |
|
|
|
else |
|
|
|
nnn |
|
|
|
fi |
|
|
|
nnn "$@" |
|
|
|
|
|
|
|
if [ -f $NNN_TMPFILE ]; then |
|
|
|
. $NNN_TMPFILE |
|
|
|
|
|
@@ -1,7 +1,7 @@ |
|
|
|
export NNN_TMPFILE="/tmp/nnn" |
|
|
|
|
|
|
|
function n --description 'support nnn quit and change directory' |
|
|
|
nnn $argv[1] |
|
|
|
nnn $argv |
|
|
|
|
|
|
|
if test -e $NNN_TMPFILE |
|
|
|
. $NNN_TMPFILE |
|
|
|
|
|
@@ -2,11 +2,7 @@ export NNN_TMPFILE="/tmp/nnn" |
|
|
|
|
|
|
|
n() |
|
|
|
{ |
|
|
|
if [ -n "$1" ]; then |
|
|
|
nnn "$1" |
|
|
|
else |
|
|
|
nnn |
|
|
|
fi |
|
|
|
nnn "$@" |
|
|
|
|
|
|
|
if [ -f $NNN_TMPFILE ]; then |
|
|
|
. $NNN_TMPFILE |
|
|
|