Swap modifiers to previous assignment because I don't want to fix them in
~/.fvwm. Assign keycode to Caps_Lock before aliasing to LCtrl so ~/.xmodmaprc
script can be re-evaluated without errors.
# -*- mode: sh; sh-shell-file: bash -*-
_gradle()
{
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 \
-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 \
-q --quiet -r --properties -s --stacktrace -t --tasks -u --no-search-upward -v --version -x --exclude-task \
--continue --daemon --foreground --no-color --no-daemon --offline --parallel --parallel-threads --project-cache-dir --recompile-scripts --refresh --refresh-dependencies \
--rerun-tasks --stop"
local _help_cmds='dependencies dependencyInsight help projects properties tasks'
local _java_cmds='assemble build buildDependents buildNeeded classes compileJava processResources clean cleanTest jar testClasses compileTestJava processTestResources javadoc check test uploadArchives'
local _application_cmds='run startScripts installApp distZip distTar'
local cur prev
cur=${COMP_WORDS[COMP_CWORD]}
[[ $COMP_CWORD != 0 ]] && prev=${COMP_WORDS[COMP_CWORD-1]}
case "$prev" in
-I|--init-script|-b|--build-file|-c|--settings-file|-e|--embedded)
COMPREPLY=( $(compgen -f -- "$cur") )
return ;;
-g|--gradle-user-home|-p|--project-dir|--project-cache-dir)
COMPREPLY=( $(compgen -d -- "$cur") )
return ;;
esac
# colonprefixes=${cur%"${cur##*:}"}
COMPREPLY=( $(compgen -W '$_opts $_help_cmds $_java_cmds $_application_cmds' -- $cur) )
# local i=${#COMPREPLY[*]}
# while [ $((--i)) -ge 0 ]; do
# COMPREPLY[$i]=${COMPREPLY[$i]#"$colonprefixes"}
# done
return 0
} &&
complete -F _gradle gradle