From 5456442807d382cccd611aa4f07095892173e695 Mon Sep 17 00:00:00 2001 From: prak132 Date: Sat, 11 Jan 2025 14:24:06 -0800 Subject: [PATCH] Test simulation workflow --- .github/workflows/simulation_check.yaml | 27 +++++++++++++++++++ .../include/frc846/robot/GenericCommand.h | 3 ++- 2 files changed, 29 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/simulation_check.yaml diff --git a/.github/workflows/simulation_check.yaml b/.github/workflows/simulation_check.yaml new file mode 100644 index 0000000..a930375 --- /dev/null +++ b/.github/workflows/simulation_check.yaml @@ -0,0 +1,27 @@ +name: Simulation Check + +on: + push: + branches: + - "**" + pull_request: + branches: + - "**" + +jobs: + simulation_check: + runs-on: ubuntu-22.04 + container: wpilib/roborio-cross-ubuntu:2025-22.04 + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Grant execute permission for gradlew + run: chmod +x gradlew + + - name: Install Roborio Toolchain + run: ./gradlew installRoborioToolchain + + - name: Spotless Check + run: ./gradlew -PenableDesktop simulateExternalNativeDebug \ No newline at end of file diff --git a/src/frc846/include/frc846/robot/GenericCommand.h b/src/frc846/include/frc846/robot/GenericCommand.h index 09cce49..c3b0ab8 100644 --- a/src/frc846/include/frc846/robot/GenericCommand.h +++ b/src/frc846/include/frc846/robot/GenericCommand.h @@ -106,7 +106,8 @@ class GenericCommandGroup private: frc2::InstantCommand end_command_addition{[&] { Log("Command group ending. Took {} ms to complete.", - (frc846::wpilib::CurrentFPGATime() - command_start_time_).to()); + (frc846::wpilib::CurrentFPGATime() - command_start_time_) + .template to()); }}; frc2::InstantCommand start_command_addition{[&] {