From 67e3a3c06cb511805c5cb3a33efa9921e5299f04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gu=C3=B0ni=20M=C3=A1r=20Gilbert?= Date: Sat, 24 Feb 2024 15:38:34 +0000 Subject: [PATCH 1/2] CI: Add sudo apt-get update See: https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/customizing-github-hosted-runners#installing-software-on-ubuntu-runners > Note: Always run sudo apt-get update before installing a package. In case the apt index is stale, this command fetches and re-indexes any available packages, which helps prevent package installation failures. --- .github/workflows/build.yml | 2 ++ .github/workflows/pr-size.yml | 1 + 2 files changed, 3 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index af2ac48..769984d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -15,6 +15,7 @@ jobs: # setup base required dependencies - name: Setup dependencies run: | + sudo apt-get update sudo apt-get install cmake ninja-build python3-pyelftools python3-regex python3-polib # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it @@ -71,6 +72,7 @@ jobs: # setup base required dependencies - name: Setup dependencies run: | + sudo apt-get update sudo apt-get install gcc-11 g++11 lcov cmake ninja-build python3-pyelftools python3-regex python3-polib # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it diff --git a/.github/workflows/pr-size.yml b/.github/workflows/pr-size.yml index e90d76e..4368b8d 100644 --- a/.github/workflows/pr-size.yml +++ b/.github/workflows/pr-size.yml @@ -18,6 +18,7 @@ jobs: # setup base required dependencies - name: Setup dependencies run: | + sudo apt-get update sudo apt-get install cmake ninja-build python3-pyelftools python3-regex python3-polib # build the base branch From cc5c425538da04c51752f1b29fa487bea36dbe77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gu=C3=B0ni=20M=C3=A1r=20Gilbert?= Date: Sat, 24 Feb 2024 15:40:46 +0000 Subject: [PATCH 2/2] CI: update cache and checkout to v4 This syncs the github actions for the MMU project with the MK3 project --- .github/workflows/build.yml | 12 ++++++------ .github/workflows/pr-size.yml | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 769984d..8629120 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -20,21 +20,21 @@ jobs: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - name: Checkout ${{ github.event.pull_request.head.ref }} - uses: actions/checkout@v3 + uses: actions/checkout@v4 if: ${{ github.event.pull_request }} with: ref: ${{ github.event.pull_request.head.sha }} submodules: true - name: Checkout ${{ github.event.ref }} - uses: actions/checkout@v3 + uses: actions/checkout@v4 if: ${{ !github.event.pull_request }} with: ref: ${{ github.event.ref }} submodules: true - name: Cache Dependencies - uses: actions/cache@v3.0.11 + uses: actions/cache@v4.0.0 id: cache-pkgs with: path: ".dependencies" @@ -77,21 +77,21 @@ jobs: # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it - name: Checkout ${{ github.event.pull_request.head.ref }} - uses: actions/checkout@v3 + uses: actions/checkout@v4 if: ${{ github.event.pull_request }} with: ref: ${{ github.event.pull_request.head.sha }} submodules: true - name: Checkout ${{ github.event.ref }} - uses: actions/checkout@v3 + uses: actions/checkout@v4 if: ${{ !github.event.pull_request }} with: ref: ${{ github.event.ref }} submodules: true - name: Cache Dependencies - uses: actions/cache@v3.0.11 + uses: actions/cache@v4.0.0 id: cache-pkgs with: path: ".dependencies" diff --git a/.github/workflows/pr-size.yml b/.github/workflows/pr-size.yml index 4368b8d..4114022 100644 --- a/.github/workflows/pr-size.yml +++ b/.github/workflows/pr-size.yml @@ -23,10 +23,10 @@ jobs: # build the base branch - name: Checkout base - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Cache Dependencies - uses: actions/cache@v3.0.11 + uses: actions/cache@v4.0.0 id: cache-pkgs with: path: ".dependencies" @@ -54,7 +54,7 @@ jobs: # build the PR branch - name: Checkout PR - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: clean: false ref: ${{ github.event.pull_request.head.sha }}