author | Oleksandr Gavenko <gavenkoa@gmail.com> |
Tue, 24 Feb 2015 00:37:27 +0200 | |
changeset 734 | da0dc50393b6 |
parent 645 | 51f6d81be3da |
child 827 | 4bd348e3422d |
permissions | -rw-r--r-- |
643 | 1 |
# -*- mode: sh; sh-shell-file: bash -*- |
2 |
||
3 |
_gradle() |
|
4 |
{ |
|
734 | 5 |
local _opts="-? -h --help -A --dep-tasks -C --cache -D --system-prop -I --init-script -P --project-prop -S --full-stacktrace -a --no-rebuild --all \ |
645
51f6d81be3da
Update options according to "gradle --help" with v1.4.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
644
diff
changeset
|
6 |
-b --build-file -c --settings-file -d --debug -e --embedded -g --gradle-user-home --gui -i --info -m --dry-run --no-opt -p --project-dir \ |
51f6d81be3da
Update options according to "gradle --help" with v1.4.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
644
diff
changeset
|
7 |
-q --quiet -r --properties -s --stacktrace -t --tasks -u --no-search-upward -v --version -x --exclude-task \ |
51f6d81be3da
Update options according to "gradle --help" with v1.4.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
644
diff
changeset
|
8 |
--continue --daemon --foreground --no-color --no-daemon --offline --parallel --parallel-threads --project-cache-dir --recompile-scripts --refresh --refresh-dependencies \ |
51f6d81be3da
Update options according to "gradle --help" with v1.4.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
644
diff
changeset
|
9 |
--rerun-tasks --stop" |
734 | 10 |
local _help_cmds='dependencies dependencyInsight help projects properties tasks' |
11 |
local _java_cmds='assemble build buildDependents buildNeeded classes compileJava processResources clean cleanTest jar testClasses compileTestJava processTestResources javadoc check test uploadArchives' |
|
12 |
local _application_cmds='run startScripts installApp distZip distTar' |
|
13 |
local cur prev |
|
14 |
cur=${COMP_WORDS[COMP_CWORD]} |
|
15 |
[[ $COMP_CWORD != 0 ]] && prev=${COMP_WORDS[COMP_CWORD-1]} |
|
16 |
case "$prev" in |
|
17 |
-I|--init-script|-b|--build-file|-c|--settings-file|-e|--embedded) |
|
18 |
COMPREPLY=( $(compgen -f -- "$cur") ) |
|
19 |
return ;; |
|
20 |
-g|--gradle-user-home|-p|--project-dir|--project-cache-dir) |
|
21 |
COMPREPLY=( $(compgen -d -- "$cur") ) |
|
22 |
return ;; |
|
23 |
esac |
|
24 |
# colonprefixes=${cur%"${cur##*:}"} |
|
25 |
COMPREPLY=( $(compgen -W '$_opts $_help_cmds $_java_cmds $_application_cmds' -- $cur) ) |
|
26 |
# local i=${#COMPREPLY[*]} |
|
27 |
# while [ $((--i)) -ge 0 ]; do |
|
28 |
# COMPREPLY[$i]=${COMPREPLY[$i]#"$colonprefixes"} |
|
29 |
# done |
|
30 |
return 0 |
|
643 | 31 |
} && |
734 | 32 |
complete -F _gradle gradle |