run_gradle
Executes Gradle commands for builds, tests, linting, and dependency checks. Prefers ./gradlew in the project directory, falling back to the global gradle binary.
Instructions
Executes a Gradle command and returns stdout. Uses ./gradlew if present in cwd, otherwise falls back to the global 'gradle' binary. Use for: build, assembleDebug, test, lint, dependencies, etc.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"command": "<command>"
},
"name": "run_gradle"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | Optional project directory (where gradlew lives). Defaults to current directory. | |
| command | Yes | The gradle task and args, e.g. 'assembleDebug' or 'test --tests PlayerViewModelTest'. |