From: "Jesper Nygårds" <jesper.nygards@gmail.com>
To: zsh-workers@zsh.org
Subject: [PATCH] gradle completion
Date: Tue, 29 Jan 2013 12:03:35 +0100 [thread overview]
Message-ID: <CABZhJg8VzSz4No7SuOnkd2PPYtdt0N8+KCx75MRA_Z-Zf94FJA@mail.gmail.com> (raw)
[-- Attachment #1.1: Type: text/plain, Size: 163 bytes --]
The attached patch makes the gradle completion avoid a time-consuming task
generation list when not needed, and updates the completion alternatives to
gradle 1.3.
[-- Attachment #1.2: Type: text/html, Size: 214 bytes --]
[-- Attachment #2: gradle.patch --]
[-- Type: application/octet-stream, Size: 3345 bytes --]
diff -ur a/Completion/Unix/Command/_gradle b/Completion/Unix/Command/_gradle
--- a/Completion/Unix/Command/_gradle 2013-01-18 10:07:59.577109800 +0100
+++ b/Completion/Unix/Command/_gradle 2013-01-21 13:21:27.800503800 +0100
@@ -24,7 +24,7 @@
zstyle -T ":completion:*:*:$service:*" gradle-inspect || gradle_inspect=no
_arguments -C \
- '(-)'{-\?,-h,--help}'[Shows this help message.]' \
+ '(-)'{-\?,-h,--help}'[Shows a help message.]' \
{-a,--no-rebuild}'[Do not rebuild project dependencies.]' \
{-b,--build-file}'[Specifies the build file.]:build file:_files -g "*.gradle(-.)"' \
{-C,--cache}'[Specifies how compiled build scripts should be cached.]:cache policy:(on rebuild)' \
@@ -45,12 +45,17 @@
'--offline[The build should operate without accessing network resources.]' \
\*{-P+,--project-prop}'[Set project property for the build script (e.g. -Pmyprop=myvalue).]:project property (prop=val):' \
{-p,--project-dir}'[Specifies the start directory for Gradle.]:start directory:_directories' \
+ '--parallel[Build projects in parallel. Gradle will attempt to determine the optimal number of executor threads to use.]' \
+ '--parallel-threads[Build projects in parallel, using the specified number of executor threads.]' \
'--profile[Profiles build execution time and generates a report in the <build_dir>/reports/profile directory.]' \
'--project-cache-dir[Specifies the project-specific cache directory.]:cache directory:_directories' \
'(-d --debug -i --info)'{-q,--quiet}'[Log errors only.]' \
- "--refresh[Refresh the state of resources of the type(s) specified.]:refresh policy:(dependencies)" \
- '(-s --stacktrace)'{-S,--full-stacktrace}'[Print out the full (very verbose) stacktrace for all exceptions.]' \
+ '--recompile-scripts[Force build script recompiling.]' \
+ '--refresh[Refresh the state of resources of the type(s) specified.]:refresh policy:(dependencies)' \
+ '--refresh-dependencies[Refresh the state of dependencies.]' \
+ '--rerun-tasks[Ignore previously cached task results.]' \
'(-S --full-stacktrace)'{-s,--stacktrace}'[Print out the stacktrace for all exceptions.]' \
+ '(-s --stacktrace)'{-S,--full-stacktrace}'[Print out the full (very verbose) stacktrace for all exceptions.]' \
'(-)--stop[Stops the Gradle daemon if it is running.]' \
{-u,--no-search-upward}"[Don't search in parent folders for a settings.gradle file.]" \
'(-)'{-v,--version}'[Print version info.]' \
@@ -58,7 +63,7 @@
'*:task:->task' \
&& ret=0
-if [[ -n $state ]]; then
+if [[ $words[CURRENT] != -* ]]; then
if [[ $gradle_inspect == yes ]]; then
# If a build file is specified after '-b' or '--build-file', use this file. Otherwise,
# default is the file 'build.gradle' in the current directory.
@@ -102,7 +107,8 @@
fi
else
_describe 'built-in tasks' '(
- "dependencies:Displays the dependencies of root project."
+ "dependencies:Displays all dependencies declared in root project."
+ "dependencyInsight:Displays the insight into a specific dependency in root project."
"help:Displays a help message."
"projects:Displays the sub-projects of root project."
"properties:Displays the properties of root project."
reply other threads:[~2013-01-29 13:59 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CABZhJg8VzSz4No7SuOnkd2PPYtdt0N8+KCx75MRA_Z-Zf94FJA@mail.gmail.com \
--to=jesper.nygards@gmail.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).