今天,我升级了我的“oh-my-zsh”,然后启动了这个错误:~/.oh-my-zsh/lib/misc.zsh:3: parse error near `then'
在这个文件里面有一个shell循环。
## Load smart urls if available
for d in $fpath; do
    if [[ -e "$url/d-quote-magic"]]; then                                                                                                 
        autoload -U url-quote-magic
        zle -N self-insert url-quote-magic
    fi
done我认为问题是在if条件下,但我没有shell/zsh技能:(有人能帮我吗?非常感谢!*)
You need a space between the " and the ]] in that if line.
因此,我只需添加一个空格:')并修复警告!:
for d in $fpath; do
    if [[ -e "$url/d-quote-magic" ]]; then                                                                                                 
        autoload -U url-quote-magic
        zle -N self-insert url-quote-magic
    fi
done相似问题
