+_git_repo_config ()
+{
+ local cur="${COMP_WORDS[COMP_CWORD]}"
+ local prv="${COMP_WORDS[COMP_CWORD-1]}"
+ case "$prv" in
+ branch.*.remote)
+ COMPREPLY=($(compgen -W "$(__git_remotes)" -- "$cur"))
+ return
+ ;;
+ branch.*.merge)
+ COMPREPLY=($(compgen -W "$(__git_refs)" -- "$cur"))
+ return
+ ;;
+ remote.*.fetch)
+ local remote="${prv#remote.}"
+ remote="${remote%.fetch}"
+ COMPREPLY=($(compgen -W "$(__git_refs_remotes "$remote")" \
+ -- "$cur"))
+ return
+ ;;
+ remote.*.push)
+ local remote="${prv#remote.}"
+ remote="${remote%.push}"
+ COMPREPLY=($(compgen -W "$(git --git-dir="$(__gitdir)" \
+ for-each-ref --format='%(refname):%(refname)' \
+ refs/heads)" -- "$cur"))
+ return
+ ;;
+ *.*)
+ COMPREPLY=()
+ return
+ ;;
+ esac
+ case "$cur" in
+ --*)
+ COMPREPLY=($(compgen -W "
+ --global --list --replace-all
+ --get --get-all --get-regexp
+ --unset --unset-all
+ " -- "$cur"))
+ return
+ ;;
+ branch.*.*)
+ local pfx="${cur%.*}."
+ cur="${cur##*.}"
+ COMPREPLY=($(compgen -P "$pfx" -W "remote merge" -- "$cur"))
+ return
+ ;;
+ branch.*)
+ local pfx="${cur%.*}."
+ cur="${cur#*.}"
+ COMPREPLY=($(compgen -P "$pfx" -S . \
+ -W "$(__git_heads)" -- "$cur"))
+ return
+ ;;
+ remote.*.*)
+ local pfx="${cur%.*}."
+ cur="${cur##*.}"
+ COMPREPLY=($(compgen -P "$pfx" -W "url fetch push" -- "$cur"))
+ return
+ ;;
+ remote.*)
+ local pfx="${cur%.*}."
+ cur="${cur#*.}"
+ COMPREPLY=($(compgen -P "$pfx" -S . \
+ -W "$(__git_remotes)" -- "$cur"))
+ return
+ ;;
+ esac
+ COMPREPLY=($(compgen -W "
+ apply.whitespace
+ core.fileMode
+ core.gitProxy
+ core.ignoreStat
+ core.preferSymlinkRefs
+ core.logAllRefUpdates
+ core.repositoryFormatVersion
+ core.sharedRepository
+ core.warnAmbiguousRefs
+ core.compression
+ core.legacyHeaders
+ i18n.commitEncoding
+ diff.color
+ diff.renameLimit
+ diff.renames
+ pager.color
+ status.color
+ log.showroot
+ show.difftree
+ showbranch.default
+ whatchanged.difftree
+ http.sslVerify
+ http.sslCert
+ http.sslKey
+ http.sslCAInfo
+ http.sslCAPath
+ http.maxRequests
+ http.lowSpeedLimit http.lowSpeedTime
+ http.noEPSV
+ pack.window
+ repack.useDeltaBaseOffset
+ pull.octopus pull.twohead
+ merge.summary
+ receive.unpackLimit
+ receive.denyNonFastForwards
+ user.name user.email
+ tar.umask
+ gitcvs.enabled
+ gitcvs.logfile
+ branch. remote.
+ " -- "$cur"))
+}
+