Skip to content

Commit

Permalink
Fix up github actions
Browse files Browse the repository at this point in the history
Change-Id: I585b96bca403c6af8c2f986e344219c472880d7c
  • Loading branch information
ThoFrank committed Jan 7, 2025
1 parent e1823c8 commit 763ff2e
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 21 deletions.
29 changes: 10 additions & 19 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,22 @@ jobs:
treefmt:
runs-on: ubuntu-latest
steps:
- name: Create user program directory
run: |
mkdir -p $HOME/.local/bin
echo "$HOME/.local/bin" >> "$GITHUB_PATH"
- uses: actions/checkout@v4

- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main

- name: Install treefmt
run: |
curl -L https://github.com/numtide/treefmt/releases/download/v2.1.0/treefmt_2.1.0_linux_amd64.tar.gz -o treefmt.tar.gz
tar -xvzf treefmt.tar.gz
install -m 755 treefmt $HOME/.local/bin
rm LICENSE README.md treefmt treefmt.tar.gz
run: nix profile install .#treefmt

- name: Install clang-format
run: |
curl -L https://github.com/muttleyxd/clang-tools-static-binaries/releases/download/master-32d3ac78/clang-format-17_linux-amd64 -o clang-format
install -m 755 clang-format $HOME/.local/bin
rm clang-format
- name: Install nixfmt
run: nix profile install .#nixfmt

- uses: actions/setup-python@v5
- name: Install clang-format
run: nix profile install .#clang-tools

- name: Install cmake-format
run: |
pip install cmakelang
- uses: actions/checkout@v4
run: nix profile install .#cmake-format

- name: Check code format
run: |
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
on: push
name: Integration Tests

on: [ merge_group, pull_request]

jobs:
integration_test:
integration-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
6 changes: 6 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@
referenceApp_S32K148 = pkgs.callPackage ./nix/referenceApp_S32K148.nix { };
udstool = pkgs.callPackage ./nix/udstool.nix { };
interactiveIntegrationTests = self.checks."${system}".integrationTests.driverInteractive;

# re-export of formatters
treefmt = treefmt.packages."${system}".default;
nixfmt = pkgs.nixfmt-rfc-style;
clang-tools = pkgs.llvmPackages_17.clang-tools;
cmake-format = pkgs.cmake-format;
};
checks = {
integrationTests = import ./nix/IntegrationTests.nix { inherit pkgs self system; };
Expand Down

0 comments on commit 763ff2e

Please sign in to comment.