Skip to content

specify specific version for NativeUtils #15

specify specific version for NativeUtils

specify specific version for NativeUtils #15

Workflow file for this run

name: Run Gradle on Merge and publish
on:
push:
branches:
- main
jobs:
gradle:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- name: Install Toolchain
run: gradle installRoboRioToolchain
- name: Execute Gradle build
run: gradle build
- name: Publish
run: gradle publish
- name: Upload a Build Artifact
if: ${{ matrix.os == 'ubuntu-latest' }}
uses: actions/[email protected]
with:
name: LibRmb.json
path: build/LibRmb.json
- name: Upload a Build Artifact
uses: actions/[email protected]
with:
name: ${{ matrix.os }}-repo
path: build/repos
publish:
needs: [gradle]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: 'maven-repo'
- name: Create archive dirs
run: mkdir -p archives/ubuntu-latest |
mkdir -p archives/macos-latest |
mkdir -p archives/windows-latest |
mkdir -p repos
- name: Download Linux Artifact
uses: actions/[email protected]
with:
name: ubuntu-latest-repo
path: archives/ubuntu-latest
- name: Download MacOS Artifact
uses: actions/[email protected]
with:
name: macos-latest-repo
path: archives/macos-latest
- name: Download Windows Artifact
uses: actions/[email protected]
with:
name: windows-latest-repo
path: archives/windows-latest
- name: Download Vendordep Json
uses: actions/[email protected]
with:
name: LibRmb.json
- name: Merge repos with rsync
run: rsync -aviuzP archives/ubuntu-latest/* ./repos |
rsync -aviuzP archives/macos-latest/* ./repos |
rsync -aviuzP archives/windows-latest/* ./repos
- name: Clean
run: rm -rf archives
- name: Commit
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "BOT: Update Repos"