.bash_completion.d/gradle
changeset 643 9f5ece28cd08
child 644 5a6d6ad8e7f4
equal deleted inserted replaced
642:8771e26315d6 643:9f5ece28cd08
       
     1 # -*- mode: sh; sh-shell-file: bash -*-
       
     2 
       
     3 _gradle()
       
     4 {
       
     5    local cmds cur colonprefixes
       
     6    COMPREPLY=()
       
     7    local _help_cmds='dependencies dependencyInsight help projects properties tasks'
       
     8    local _java_cmds='assemble build buildDependents buildNeeded classes compileJava processResources clean cleanTest jar testClasses compileTestJava processTestResources javadoc check test uploadArchives'
       
     9    cur=${COMP_WORDS[COMP_CWORD]}
       
    10    # colonprefixes=${cur%"${cur##*:}"}
       
    11    COMPREPLY=( $(compgen -W '$_help_cmds $_java_cmds'  -- $cur) )
       
    12    # local i=${#COMPREPLY[*]}
       
    13    # while [ $((--i)) -ge 0 ]; do
       
    14    #    COMPREPLY[$i]=${COMPREPLY[$i]#"$colonprefixes"}
       
    15    # done
       
    16    return 0
       
    17 } &&
       
    18 complete -F _gradle gradle