contrib/bash_completion
changeset 3476 13a9a2136dd7
parent 3475 03932425cfd8
child 3477 e762c0e95eac
equal deleted inserted replaced
3475:03932425cfd8 3476:13a9a2136dd7
   191 
   191 
   192     case "$cmd" in
   192     case "$cmd" in
   193 	help)
   193 	help)
   194 	    _hg_commands
   194 	    _hg_commands
   195 	;;
   195 	;;
   196 	export|manifest|update)
   196 	export)
       
   197 	    if _hg_ext_mq_patchlist qapplied && [ "${COMPREPLY[*]}" ]; then
       
   198 		return 0
       
   199 	    fi
       
   200 	    _hg_tags
       
   201 	;;
       
   202 	manifest|update)
   197 	    _hg_tags
   203 	    _hg_tags
   198 	;;
   204 	;;
   199 	pull|push|outgoing|incoming)
   205 	pull|push|outgoing|incoming)
   200 	    _hg_paths
   206 	    _hg_paths
   201 	    _hg_repos
   207 	    _hg_repos
   314     local root=$("$hg" root 2>/dev/null)
   320     local root=$("$hg" root 2>/dev/null)
   315     # this is run in a sub-shell, so we can't use _hg_status
   321     # this is run in a sub-shell, so we can't use _hg_status
   316     local files=$(cd "$root/.hg/patches" 2>/dev/null &&
   322     local files=$(cd "$root/.hg/patches" 2>/dev/null &&
   317                   "$hg" status -nmar 2>/dev/null)
   323                   "$hg" status -nmar 2>/dev/null)
   318     COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$files' -- "$cur"))
   324     COMPREPLY=(${COMPREPLY[@]:-} $(compgen -W '$files' -- "$cur"))
   319 }
       
   320 
       
   321 _hg_cmd_export()
       
   322 {
       
   323     _hg_ext_mq_patchlist qapplied
       
   324 }
   325 }
   325 
   326 
   326 
   327 
   327 # hbisect
   328 # hbisect
   328 _hg_cmd_bisect()
   329 _hg_cmd_bisect()