{"action":"created","issue":{"url":"https://api.github.com/repos/babun/babun/issues/370","labels_url":"https://api.github.com/repos/babun/babun/issues/370/labels{/name}","comments_url":"https://api.github.com/repos/babun/babun/issues/370/comments","events_url":"https://api.github.com/repos/babun/babun/issues/370/events","html_url":"https://github.com/babun/babun/issues/370","id":89974846,"number":370,"title":"A couple of days ago I updated Babun and now I get lots of errors when I start it up and it doesn't recognize git and grep either","user":{"login":"behrangsa","id":18451,"avatar_url":"https://avatars.githubusercontent.com/u/18451?v=3","gravatar_id":"","url":"https://api.github.com/users/behrangsa","html_url":"https://github.com/behrangsa","followers_url":"https://api.github.com/users/behrangsa/followers","following_url":"https://api.github.com/users/behrangsa/following{/other_user}","gists_url":"https://api.github.com/users/behrangsa/gists{/gist_id}","starred_url":"https://api.github.com/users/behrangsa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/behrangsa/subscriptions","organizations_url":"https://api.github.com/users/behrangsa/orgs","repos_url":"https://api.github.com/users/behrangsa/repos","events_url":"https://api.github.com/users/behrangsa/events{/privacy}","received_events_url":"https://api.github.com/users/behrangsa/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-21T23:36:06Z","updated_at":"2015-06-21T23:52:36Z","closed_at":null,"body":"Please find the output attached:\r\n\r\n```\r\nExecuting daily babun check:\r\nSource consistent [OK]\r\nPrompt speed      [OK]\r\nFile permissions  [OK]\r\nConnection check  [OK]\r\nUpdate check      [OK]\r\nCygwin check      [OK]\r\nfind: ‘/cygdrive/p’: Permission denied\r\ncolors () {\r\n        emulate -L zsh\r\n        typeset -Ag color colour\r\n        color=(00 none 01 bold 02 faint 22 normal 03 standout 23 no-standout 04 underline 24 no-underline 05 blink 25 no-blink 07 reverse 27 no-reverse 08 conceal 28 no-conceal 30 black 40 bg-black 31 red 41 bg-red 32 green 42 bg-green 33 yellow 43 bg-yellow 34 blue 44 bg-blue 35 magenta 45 bg-magenta 36 cyan 46 bg-cyan 37 white 47 bg-white 39 default 49 bg-default)\r\n        local k\r\n        for k in ${(k)color}\r\n        do\r\n                color[${color[$k]}]=$k\r\n        done\r\n        for k in ${color[(I)3?]}\r\n        do\r\n                color[fg-${color[$k]}]=$k\r\n        done\r\n        color[grey]=${color[black]}\r\n        color[fg-grey]=${color[grey]}\r\n        color[bg-grey]=${color[bg-black]}\r\n        colour=(${(kv)color})\r\n        local lc=$'\\e[' rc=m\r\n        typeset -Hg reset_color bold_color\r\n        reset_color=\"$lc${color[none]}$rc\"\r\n        bold_color=\"$lc${color[bold]}$rc\"\r\n        typeset -AHg fg fg_bold fg_no_bold\r\n        for k in ${(k)color[(I)fg-*]}\r\n        do\r\n                fg[${k#fg-}]=\"$lc${color[$k]}$rc\"\r\n                fg_bold[${k#fg-}]=\"$lc${color[bold]};${color[$k]}$rc\"\r\n                fg_no_bold[${k#fg-}]=\"$lc${color[normal]};${color[$k]}$rc\"\r\n        done\r\n        typeset -AHg bg bg_bold bg_no_bold\r\n        for k in ${(k)color[(I)bg-*]}\r\n        do\r\n                bg[${k#bg-}]=\"$lc${color[$k]}$rc\"\r\n                bg_bold[${k#bg-}]=\"$lc${color[bold]};${color[$k]}$rc\"\r\n                bg_no_bold[${k#bg-}]=\"$lc${color[normal]};${color[$k]}$rc\"\r\n        done\r\n}\r\ncompdump () {\r\n        # undefined\r\n        builtin autoload -XUz\r\n}\r\ncompinit () {\r\n        emulate -L zsh\r\n        setopt extendedglob\r\n        typeset _i_dumpfile _i_files _i_line _i_done _i_dir _i_autodump=1\r\n        typeset _i_tag _i_file _i_addfiles _i_fail=ask _i_check=yes _i_name\r\n        while [[ $# -gt 0 && $1 = -[dDiuC] ]]\r\n        do\r\n                case \"$1\" in\r\n                        (-d) _i_autodump=1\r\n                                shift\r\n                                if [[ $# -gt 0 && \"$1\" != -[dfQC] ]]\r\n                                then\r\n                                        _i_dumpfile=\"$1\"\r\n                                        shift\r\n                                fi ;;\r\n                        (-D) _i_autodump=0\r\n                                shift ;;\r\n                        (-i) _i_fail=ign\r\n                                shift ;;\r\n                        (-u) _i_fail=use\r\n                                shift ;;\r\n                        (-C) _i_check=\r\n                                shift ;;\r\n                esac\r\n        done\r\n        typeset -gA _comps _services _patcomps _postpatcomps\r\n        typeset -gA _compautos\r\n        typeset -gA _lastcomp\r\n        if [[ -n $_i_dumpfile ]]\r\n        then\r\n                typeset -g _comp_dumpfile=\"$_i_dumpfile\"\r\n        else\r\n                typeset -g _comp_dumpfile=\"${ZDOTDIR:-$HOME}/.zcompdump\"\r\n        fi\r\n        typeset -ga _comp_options\r\n        _comp_options=(bareglobqual extendedglob glob multibyte nullglob rcexpandparam unset NO_allexport NO_aliases NO_cshnullglob NO_cshjunkiequotes NO_errexit NO_globsubst NO_histsubstpattern NO_ignorebraces NO_ignoreclosebraces NO_kshglob NO_ksharrays NO_kshtypeset NO_markdirs NO_octalzeroes NO_shwordsplit NO_shglob NO_warncreateglobal)\r\n        typeset -g _comp_setup='local -A _comp_caller_options;\r\n             _comp_caller_options=(${(kv)options[@]});\r\n             setopt localoptions localtraps localpatterns ${_comp_options[@]};\r\n             local IFS=$'\\'\\ \\\\t\\\\r\\\\n\\\\0\\''\r\n             enable -p \\| \\~ \\( \\? \\* \\[ \\< \\^ \\#\r\n             exec </dev/null;\r\n             trap - ZERR\r\n             local -a reply\r\n             local REPLY'\r\n        typeset -ga compprefuncs comppostfuncs\r\n        compprefuncs=()\r\n        comppostfuncs=()\r\n        : $funcstack\r\n        compdef () {\r\n                local opt autol type func delete eval new i ret=0 cmd svc\r\n                local -a match mbegin mend\r\n                emulate -L zsh\r\n                setopt extendedglob\r\n                if (( ! $# ))\r\n                then\r\n                        print -u2 \"$0: I need arguments\"\r\n                        return 1\r\n                fi\r\n                while getopts \"anpPkKde\" opt\r\n                do\r\n                        case \"$opt\" in\r\n                                (a) autol=yes  ;;\r\n                                (n) new=yes  ;;\r\n                                ([pPkK]) if [[ -n \"$type\" ]]\r\n                                        then\r\n                                                print -u2 \"$0: type already set to $type\"\r\n                                                return 1\r\n                                        fi\r\n                                        if [[ \"$opt\" = p ]]\r\n                                        then\r\n                                                type=pattern\r\n                                        elif [[ \"$opt\" = P ]]\r\n                                        then\r\n                                                type=postpattern\r\n                                        elif [[ \"$opt\" = K ]]\r\n                                        then\r\n                                                type=widgetkey\r\n                                        else\r\n                                                type=key\r\n                                        fi ;;\r\n                                (d) delete=yes  ;;\r\n                                (e) eval=yes  ;;\r\n                        esac\r\n                done\r\n                shift OPTIND-1\r\n                if (( ! $# ))\r\n                then\r\n                        print -u2 \"$0: I need arguments\"\r\n                        return 1\r\n                fi\r\n                if [[ -z \"$delete\" ]]\r\n                then\r\n                        if [[ -z \"$eval\" ]] && [[ \"$1\" = *\\=* ]]\r\n                        then\r\n                                while (( $# ))\r\n                                do\r\n                                        if [[ \"$1\" = *\\=* ]]\r\n                                        then\r\n                                                cmd=\"${1%%\\=*}\"\r\n                                                svc=\"${1#*\\=}\"\r\n                                                func=\"$_comps[${_services[(r)$svc]:-$svc}]\"\r\n                                                [[ -n ${_services[$svc]} ]] && svc=${_services[$svc]}\r\n                                                [[ -z \"$func\" ]] && func=\"${${_patcomps[(K)$svc][1]}:-${_postpatcomps[(K)$svc][1]}}\"\r\n                                                if [[ -n \"$func\" ]]\r\n                                                then\r\n                                                        _comps[$cmd]=\"$func\"\r\n                                                        _services[$cmd]=\"$svc\"\r\n                                                else\r\n                                                        print -u2 \"$0: unknown command or service: $svc\"\r\n                                                        ret=1\r\n                                                fi\r\n                                        else\r\n                                                print -u2 \"$0: invalid argument: $1\"\r\n                                                ret=1\r\n                                        fi\r\n                                        shift\r\n                                done\r\n                                return ret\r\n                        fi\r\n                        func=\"$1\"\r\n                        [[ -n \"$autol\" ]] && autoload -Uz \"$func\"\r\n                        shift\r\n                        case \"$type\" in\r\n                                (widgetkey) while [[ -n $1 ]]\r\n                                        do\r\n                                                if [[ $# -lt 3 ]]\r\n                                                then\r\n                                                        print -u2 \"$0: compdef -K requires <widget> <comp-widget> <key>\"\r\n                                                        return 1\r\n                                                fi\r\n                                                [[ $1 = _* ]] || 1=\"_$1\"\r\n                                                [[ $2 = .* ]] || 2=\".$2\"\r\n                                                [[ $2 = .menu-select ]] && zmodload -i zsh/complist\r\n                                                zle -C \"$1\" \"$2\" \"$func\"\r\n                                                if [[ -n $new ]]\r\n                                                then\r\n                                                        bindkey \"$3\" | IFS=$' \\t' read -A opt\r\n                                                        [[ $opt[-1] = undefined-key ]] && bindkey \"$3\" \"$1\"\r\n                                                else\r\n                                                        bindkey \"$3\" \"$1\"\r\n                                                fi\r\n                                                shift 3\r\n                                        done ;;\r\n                                (key) if [[ $# -lt 2 ]]\r\n                                        then\r\n                                                print -u2 \"$0: missing keys\"\r\n                                                return 1\r\n                                        fi\r\n                                        if [[ $1 = .* ]]\r\n                                        then\r\n                                                [[ $1 = .menu-select ]] && zmodload -i zsh/complist\r\n                                                zle -C \"$func\" \"$1\" \"$func\"\r\n                                        else\r\n                                                [[ $1 = menu-select ]] && zmodload -i zsh/complist\r\n                                                zle -C \"$func\" \".$1\" \"$func\"\r\n                                        fi\r\n                                        shift\r\n                                        for i\r\n                                        do\r\n                                                if [[ -n $new ]]\r\n                                                then\r\n                                                        bindkey \"$i\" | IFS=$' \\t' read -A opt\r\n                                                        [[ $opt[-1] = undefined-key ]] || continue\r\n                                                fi\r\n                                                bindkey \"$i\" \"$func\"\r\n                                        done ;;\r\n                                (*) while (( $# ))\r\n                                        do\r\n                                                if [[ \"$1\" = -N ]]\r\n                                                then\r\n                                                        type=normal\r\n                                                elif [[ \"$1\" = -p ]]\r\n                                                then\r\n                                                        type=pattern\r\n                                                elif [[ \"$1\" = -P ]]\r\n                                                then\r\n                                                        type=postpattern\r\n                                                else\r\n                                                        case \"$type\" in\r\n                                                                (pattern) if [[ $1 = (#b)(*)=(*) ]]\r\n                                                                        then\r\n                                                                                _patcomps[$match[1]]=\"=$match[2]=$func\"\r\n                                                                        else\r\n                                                                                _patcomps[$1]=\"$func\"\r\n                                                                        fi ;;\r\n                                                                (postpattern) if [[ $1 = (#b)(*)=(*) ]]\r\n                                                                        then\r\n                                                                                _postpatcomps[$match[1]]=\"=$match[2]=$func\"\r\n                                                                        else\r\n                                                                                _postpatcomps[$1]=\"$func\"\r\n                                                                        fi ;;\r\n                                                                (*) if [[ \"$1\" = *\\=* ]]\r\n                                                                        then\r\n                                                                                cmd=\"${1%%\\=*}\"\r\n                                                                                svc=yes\r\n                                                                        else\r\n                                                                                cmd=\"$1\"\r\n                                                                                svc=\r\n                                                                        fi\r\n                                                                        if [[ -z \"$new\" || -z \"${_comps[$1]}\" ]]\r\n                                                                        then\r\n                                                                                _comps[$cmd]=\"$func\"\r\n                                                                                [[ -n \"$svc\" ]] && _services[$cmd]=\"${1#*\\=}\"\r\n                                                                        fi ;;\r\n                                                        esac\r\n                                                fi\r\n                                                shift\r\n                                        done ;;\r\n                        esac\r\n                else\r\n                        case \"$type\" in\r\n                                (pattern) unset \"_patcomps[$^@]\" ;;\r\n                                (postpattern) unset \"_postpatcomps[$^@]\" ;;\r\n                                (key) print -u2 \"$0: cannot restore key bindings\"\r\n                                        return 1 ;;\r\n                                (*) unset \"_comps[$^@]\" ;;\r\n                        esac\r\n                fi\r\n        }\r\n        typeset _i_wdirs _i_wfiles\r\n        _i_wdirs=()\r\n        _i_wfiles=()\r\n        autoload -Uz compaudit\r\n        if [[ -n \"$_i_check\" ]]\r\n        then\r\n                typeset _i_q\r\n                if ! eval compaudit\r\n                then\r\n                        if [[ -n \"$_i_q\" ]]\r\n                        then\r\n                                if [[ \"$_i_fail\" = ask ]]\r\n                                then\r\n                                        if ! read -q \"?zsh compinit: insecure $_i_q, run compaudit for list.\r\nIgnore insecure $_i_q and continue [y] or abort compinit [n]? \"\r\n                                        then\r\n                                                print -u2 \"$0: initialization aborted\"\r\n                                                unfunction compinit compdef\r\n                                                unset _comp_dumpfile _comp_secure compprefuncs comppostfuncs _comps _patcomps _postpatcomps _compautos _lastcomp\r\n                                                return 1\r\n                                        fi\r\n                                        _i_wfiles=()\r\n                                        _i_wdirs=()\r\n                                else\r\n                                        (( $#_i_wfiles )) && _i_files=(\"${(@)_i_files:#(${(j:|:)_i_wfiles%.zwc})}\")\r\n                                        (( $#_i_wdirs )) && _i_files=(\"${(@)_i_files:#(${(j:|:)_i_wdirs%.zwc})/*}\")\r\n                                fi\r\n                        fi\r\n                        typeset -g _comp_secure=yes\r\n                fi\r\n        fi\r\n        autoload -Uz compdump compinstall\r\n        _i_done=''\r\n        if [[ -f \"$_comp_dumpfile\" ]]\r\n        then\r\n                if [[ -n \"$_i_check\" ]]\r\n                then\r\n                        IFS=$' \\t' read -rA _i_line < \"$_comp_dumpfile\"\r\n                        if [[ _i_autodump -eq 1 && $_i_line[2] -eq $#_i_files && $ZSH_VERSION = $_i_line[4] ]]\r\n                        then\r\n                                builtin . \"$_comp_dumpfile\"\r\n                                _i_done=yes\r\n                        fi\r\n                else\r\n                        builtin . \"$_comp_dumpfile\"\r\n                        _i_done=yes\r\n                fi\r\n        fi\r\n        if [[ -z \"$_i_done\" ]]\r\n        then\r\n                typeset -A _i_test\r\n                for _i_dir in $fpath\r\n                do\r\n                        [[ $_i_dir = . ]] && continue\r\n                        (( $_i_wdirs[(I)$_i_dir] )) && continue\r\n                        for _i_file in $_i_dir/^([^_]*|*~|*.zwc)(N)\r\n                        do\r\n                                _i_name=\"${_i_file:t}\"\r\n                                (( $+_i_test[$_i_name] + $_i_wfiles[(I)$_i_file] )) && continue\r\n                                _i_test[$_i_name]=yes\r\n                                IFS=$' \\t' read -rA _i_line < $_i_file\r\n                                _i_tag=$_i_line[1]\r\n                                shift _i_line\r\n                                case $_i_tag in\r\n                                        (\\#compdef) if [[ $_i_line[1] = -[pPkK](n|) ]]\r\n                                                then\r\n                                                        compdef ${_i_line[1]}na \"${_i_name}\" \"${(@)_i_line[2,-1]}\"\r\n                                                else\r\n                                                        compdef -na \"${_i_name}\" \"${_i_line[@]}\"\r\n                                                fi ;;\r\n                                        (\\#autoload) autoload -Uz \"$_i_line[@]\" ${_i_name}\r\n                                                [[ \"$_i_line\" != \\ # ]] && _compautos[${_i_name}]=\"$_i_line\"  ;;\r\n                                esac\r\n                        done\r\n                done\r\n                if [[ $_i_autodump = 1 ]]\r\n                then\r\n                        compdump\r\n                fi\r\n        fi\r\n        for _i_line in complete-word delete-char-or-list expand-or-complete expand-or-complete-prefix list-choices menu-complete menu-expand-or-complete reverse-menu-complete\r\n        do\r\n                zle -C $_i_line .$_i_line _main_complete\r\n        done\r\n        zle -la menu-select && zle -C menu-select .menu-select _main_complete\r\n        bindkey '^i' | IFS=$' \\t' read -A _i_line\r\n        if [[ ${_i_line[2]} = expand-or-complete ]] && zstyle -a ':completion:' completer _i_line && (( ${_i_line[(i)_expand]} <= ${#_i_line} ))\r\n        then\r\n                bindkey '^i' complete-word\r\n        fi\r\n        unfunction compinit compaudit\r\n        autoload -Uz compinit compaudit\r\n        return 0\r\n}\r\ncompinstall () {\r\n        # undefined\r\n        builtin autoload -XUz\r\n}\r\nedit-command-line () {\r\n        # undefined\r\n        builtin autoload -XU\r\n}\r\nurl-quote-magic () {\r\n        # undefined\r\n        builtin autoload -XU\r\n}\r\ncompdef: unknown command or service: git\r\ncompdef: unknown command or service: grep\r\ncompdef: unknown command or service: git\r\n```"},"comment":{"url":"https://api.github.com/repos/babun/babun/issues/comments/113969625","html_url":"https://github.com/babun/babun/issues/370#issuecomment-113969625","issue_url":"https://api.github.com/repos/babun/babun/issues/370","id":113969625,"user":{"login":"behrangsa","id":18451,"avatar_url":"https://avatars.githubusercontent.com/u/18451?v=3","gravatar_id":"","url":"https://api.github.com/users/behrangsa","html_url":"https://github.com/behrangsa","followers_url":"https://api.github.com/users/behrangsa/followers","following_url":"https://api.github.com/users/behrangsa/following{/other_user}","gists_url":"https://api.github.com/users/behrangsa/gists{/gist_id}","starred_url":"https://api.github.com/users/behrangsa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/behrangsa/subscriptions","organizations_url":"https://api.github.com/users/behrangsa/orgs","repos_url":"https://api.github.com/users/behrangsa/repos","events_url":"https://api.github.com/users/behrangsa/events{/privacy}","received_events_url":"https://api.github.com/users/behrangsa/received_events","type":"User","site_admin":false},"created_at":"2015-06-21T23:52:36Z","updated_at":"2015-06-21T23:52:36Z","body":"Looks like running this fixes the problem:\r\n\r\n```\r\n$ compinit\r\n$ cp .zcompdump .zcompdump-$HOSTNAME-5.0.6\r\n```"}}