GradleCmd returns the command that should be used to invoke gradle for this build.
(ctx *gcp.Context)
| 205 | |
| 206 | // GradleCmd returns the command that should be used to invoke gradle for this build. |
| 207 | func GradleCmd(ctx *gcp.Context) (string, error) { |
| 208 | exists, err := ctx.FileExists("gradlew") |
| 209 | if err != nil { |
| 210 | return "", err |
| 211 | } |
| 212 | // If this project has the Gradle Wrapper, we should use it |
| 213 | if exists { |
| 214 | return "./gradlew", nil |
| 215 | } |
| 216 | return "gradle", nil |
| 217 | } |
no test coverage detected