Skip to content

Commit

Permalink
updated module :gradlew
Browse files Browse the repository at this point in the history
  • Loading branch information
juerg committed Jan 12, 2024
1 parent e320f96 commit 0819c70
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions src/main/resources/com/github/jlangch/venice/gradlew.venice
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,12 @@

(defn version
^{ :arglists '("(gradlew/version)")
:doc "Returns the Gradle version"
:doc
"""
Returns the Gradle version

**Note: Use this module only for projects based on the Gradle wrapper**
"""
:examples '(
"""
(do
Expand All @@ -52,6 +57,8 @@
"""
Runs one or more Gradle tasks.

**Note: Use this module only for projects based on the Gradle wrapper**

Arguments:

| proj-home d | The project directory |
Expand Down Expand Up @@ -99,16 +106,18 @@
Runs one or more Gradle tasks and prints a list of the tasks and the
options taken from the passed arguments.

**Note: Use this module only for projects based on the Gradle wrapper**

Apart from printing the information the function is identical to
`gradlew/run`.

Arguments:

| proj-home d | The project directory |
| :out-fn f | a function with a single string argument that receives \
line by line from the process' stdout. |
line by line from the process' stdout. May be nil. |
| :err-fn f | a function with a single string argument that receives \
line by line from the process' stderr. |
line by line from the process' stderr. May be nil. |
| args | Any number of task names and Gradle options |
"""
:examples '(
Expand All @@ -135,9 +144,9 @@
options (filter #(str/starts-with? % "-") args)
script (gradlew-script-path proj-home)]
(assert (io/exists-file? script) "Gradle wrapper '~{script}' not existing!")
(println (str "Gradle script: " gradle-script))
(println (str "Gradle script: " script))
(println (str "Gradle tasks: " (str/join ", " tasks)))
(println (str "Gradle options: " all-options))
(println (str "Gradle options: " options))
((exec) (str/join " " (concat [script] options tasks))
:dir proj-home
:out-fn out-fn
Expand Down

0 comments on commit 0819c70

Please sign in to comment.