diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml new file mode 100644 index 0000000..c43ff4b --- /dev/null +++ b/.github/workflows/gradle.yml @@ -0,0 +1,43 @@ +# This workflow uses actions that are not certified by GitHub. +# They are provided by a third-party and are governed by +# separate terms of service, privacy policy, and support +# documentation. +# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle + +name: Java CI with Gradle + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +# If your gradlew file is contained in a different subfolder, uncomment the following 3 lines +# and add whatever folder it's contained in as "working-directory:" +# defaults: +# run: +# working-directory: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + build: + # The type of runner that the job will run on + runs-on: ubuntu-latest + + # This grabs the WPILib docker container + container: wpilib/roborio-cross-ubuntu:2024-22.04 + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v4 + + # Grant execute permission for gradlew + - name: Grant execute permission for gradlew + run: chmod +x gradlew + + # Runs a single command using the runners shell + - name: Compile and run tests on robot code + run: ./gradlew build \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..c86cd76 --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +[![Java CI with Gradle](https://github.com/Team612/612-2024-Crescendo/actions/workflows/gradle.yml/badge.svg)](https://github.com/Team612/612-2024-Crescendo/actions/workflows/gradle.yml) \ No newline at end of file