Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: BUG: failure in "vcs_info prompt" aborts precmd function



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 22.11.2014 23:20, Mikael Magnusson wrote:

>> Apart from that, I am still wondering why the error in vcs_info causes abortion of the precmd function?!
> 
> Passing a non-existing file to $(< is a fatal error, or whichever term
> is correct here.

I got that, but e.g. `false` does not abort the precmd function.

I am using vcs_info like this:

    if (( $ZSH_IS_SLOW_DIR )) || ! vcs_info 'prompt'; then
        # No vcs_info available, only set cwd
        prompt_vcs=""
    else
        prompt_vcs="${PR_RESET}$vcs_info_msg_0_"
        if ! zstyle -t ':vcs_info:*:prompt:*' 'check-for-changes'; then
            prompt_vcs+=' ?'
        fi
        rprompt_extra+=("${vcs_info_msg_1_}")
    fi


Regards,
Daniel.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iD8DBQFUcgQPfAK/hT/mPgARAii4AJ92A0NFg8Np8qSrNWfO/V9n0xonjwCfbyRS
VIO+Y1tkr0gZ2rm4QyYzELk=
=/FPk
-----END PGP SIGNATURE-----



Messages sorted by: Reverse Date, Date, Thread, Author