tianhao / alfred-mweb-workflow

搜索、打开MWeb 内部文档和外部 Markdown 文档
MIT License
221 stars 16 forks source link

mpush 功能调试出现错误 #14

Closed sillybun closed 5 years ago

sillybun commented 5 years ago

我打开了workflow的debug功能,虽然mpush能够正常运行,但是跳出了这样的错误:

[2019-04-01 09:00:45][ERROR: action.script] /Users/zhangyiteng/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Scripts/9A5C9356-CC16-44C6-AC42-395333EE0936: line 1: [: too many arguments
tianhao commented 5 years ago

可以把开头的if ... fi 改拆成两个if

if [ -z "${MBLOG_HOME}" ];then
   exit 1
fi
if [ ! -d "${MBLOG_HOME}" ];then
   exit 1
fi
sillybun commented 5 years ago

谢谢!