Update examples for 2025 beta 2 #219
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a faster workflow that parallelizes the jobs in a matrix so | |
# we can get faster results than waiting for the standard build_all_frc_projects | |
# powershell script | |
name: Build all FRC Projects | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
permissions: | |
contents: read | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- project-name: 'ArcadeDrive' | |
directory: 'cpp/ArcadeDrive' | |
- project-name: 'BasicLatencyCompensation' | |
directory: 'cpp/BasicLatencyCompensation' | |
- project-name: 'CANcoder' | |
directory: 'cpp/CANcoder' | |
- project-name: 'CommandBasedDrive' | |
directory: 'cpp/CommandBasedDrive' | |
- project-name: 'ControlRequestLimits' | |
directory: 'cpp/ControlRequestLimits' | |
- project-name: 'CurrentLimits' | |
directory: 'cpp/CurrentLimits' | |
- project-name: 'FusedCANcoder' | |
directory: 'cpp/FusedCANcoder' | |
- project-name: 'MotionMagic' | |
directory: 'cpp/MotionMagic' | |
- project-name: 'PhoenixSysId' | |
directory: 'cpp/PhoenixSysId' | |
- project-name: 'Pigeon2' | |
directory: 'cpp/Pigeon2' | |
- project-name: 'PositionClosedLoop' | |
directory: 'cpp/PositionClosedLoop' | |
- project-name: 'Simulation' | |
directory: 'cpp/Simulation' | |
- project-name: 'VelocityClosedLoop' | |
directory: 'cpp/VelocityClosedLoop' | |
- project-name: 'WaitForAll' | |
directory: 'cpp/WaitForAll' | |
- project-name: 'ArcadeDrive' | |
directory: 'java/ArcadeDrive' | |
- project-name: 'BasicLatencyCompensation' | |
directory: 'java/BasicLatencyCompensation' | |
- project-name: 'CANcoder' | |
directory: 'java/CANcoder' | |
- project-name: 'CommandBasedDrive' | |
directory: 'java/CommandBasedDrive' | |
- project-name: 'ControlRequestLimits' | |
directory: 'java/ControlRequestLimits' | |
- project-name: 'CurrentLimits' | |
directory: 'java/CurrentLimits' | |
- project-name: 'FusedCANcoder' | |
directory: 'java/FusedCANcoder' | |
- project-name: 'MotionMagic' | |
directory: 'java/MotionMagic' | |
- project-name: 'PhoenixSysId' | |
directory: 'java/PhoenixSysId' | |
- project-name: 'Pigeon2' | |
directory: 'java/Pigeon2' | |
- project-name: 'PositionClosedLoop' | |
directory: 'java/PositionClosedLoop' | |
- project-name: 'Simulation' | |
directory: 'java/Simulation' | |
- project-name: 'SwerveWithPathPlanner' | |
directory: 'java/SwerveWithPathPlanner' | |
- project-name: 'VelocityClosedLoop' | |
directory: 'java/VelocityClosedLoop' | |
- project-name: 'WaitForAll' | |
directory: 'java/WaitForAll' | |
# 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: | |
- uses: actions/checkout@v4 | |
# Grant execute permission for gradlew | |
- name: Grant execute permission for gradlew | |
run: cd "${{ matrix.directory }}" && chmod +x gradlew | |
# Runs a single command using the runners shell | |
- name: Compile and run tests on robot code for project ${{ matrix.project-name }} | |
run: cd "${{ matrix.directory }}" && ./gradlew build | |
build-python: | |
strategy: | |
fail-fast: false | |
matrix: | |
python_version: ['3.9', '3.10', '3.11'] | |
os: ['ubuntu-22.04', 'macos-12', 'windows-2022'] | |
project-name: ['ArcadeDrive', 'CANcoder', 'MotionMagic', 'PhoenixSysId', 'PositionClosedLoop', 'StatusSignals', 'TalonFX', 'VelocityClosedLoop'] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python_version }} | |
- name: Install python dependencies | |
run: | | |
pip install -U pip | |
pip install -U --pre robotpy robotpy-commands-v2 robotpy-pathplannerlib phoenix6 | |
- name: Test ${{ matrix.project-name }} | |
run: | | |
cd "python/${{ matrix.project-name }}" && python3 -m robotpy test |