gradle-build-action/README.md

41 lines
1.1 KiB
Markdown
Raw Permalink Normal View History

2024-01-26 17:43:38 +00:00
> [!IMPORTANT]
> As of `v3` this action has been superceded by `gradle/actions/setup-gradle`.
> Any workflow that uses `gradle/gradle-build-action@v3` will transparently delegate to `gradle/actions/setup-gradle@v3`.
>
> Users are encouraged to update their workflows, replacing:
> ```
> uses: gradle/gradle-build-action@v3
> ```
>
> with
> ```
> uses: gradle/actions/setup-gradle@v3
> ```
>
> See the [setup-gradle documentation](https://github.com/gradle/actions/tree/main/setup-gradle) for up-to-date documentation for `gradle/actions/setup-gradle`.
2024-01-26 17:43:38 +00:00
2024-08-07 22:48:29 +00:00
# Setup Gradle for use in GitHub Actions workflows
2019-09-20 21:06:59 +00:00
2024-08-07 22:48:29 +00:00
This GitHub Action can be used to configure Gradle on any platform supported by GitHub Actions.
2019-09-20 21:06:59 +00:00
## Example usage
```yaml
name: Build
2024-01-01 20:48:08 +00:00
on: [ push ]
2023-08-20 22:27:48 +00:00
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
2023-08-20 22:27:48 +00:00
- name: Setup Gradle
2024-08-07 22:48:29 +00:00
uses: gradle/actions/setup-gradle@v3
- name: Build with Gradle
2023-08-20 22:27:48 +00:00
run: ./gradlew build
```
See the [full setup-gradle documentation](https://github.com/gradle/actions/tree/main/setup-gradle) for more advanced usage scenarios.