Skip to content

CI: Remove ENV from var. #4

CI: Remove ENV from var.

CI: Remove ENV from var. #4

Workflow file for this run

name: CMake
on:
push:
pull_request:
release:
types: [created]
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
jobs:
build:
name: Linux
runs-on: ubuntu-22.04
env:
CI_PROJECT_ROOT: ${{ github.workspace }}/src-${{ github.sha }}
CI_BUILD_ROOT: ${{ github.workspace }}
steps:
- name: Prepare Code
uses: actions/checkout@v4
with:
path: src-${{ github.sha }}
submodules: true
- name: Install Arm GNU Toolchain (arm-none-eabi-gcc)
uses: carlosperate/arm-none-eabi-gcc-action@v1
with:
release: '13.3.Rel1'
- name: "Prepare tools & dependencies"
shell: bash
run: |
source $CI_PROJECT_ROOT/ci/cpp.sh && ci_debug
ci_prepare_all
- name: "CMake: Configure"
shell: bash
run: |
source $CI_PROJECT_ROOT/ci/cpp.sh && ci_debug
ci_cmake_configure
- name: "CMake: Build"
shell: bash
run: |
source $CI_PROJECT_ROOT/ci/cpp.sh && ci_debug
ci_cmake_build
ci_cmake_package
- name: "CMake: Post"
shell: bash
run: |
echo "RELEASE_FILE=$(ls ${{ env.CI_BUILD_ROOT }}/*.uf2 | cut -d. -f1)" >> $GITHUB_ENV
- name: "Artifacts: Upload .uf2"
uses: actions/upload-artifact@v4
with:
name: ${{ env.RELEASE_FILE }}.uf2
path: ${{ env.CI_BUILD_ROOT }}/${{ env.RELEASE_FILE }}.uf2
- name: "Release: Upload Files"
if: github.event_name == 'release'
uses: softprops/action-gh-release@v1
with:
files: |
${{ env.CI_BUILD_ROOT }}/${{ env.RELEASE_FILE }}.uf2
${{ env.CI_BUILD_ROOT }}/${{ env.RELEASE_FILE }}.zip
${{ env.CI_BUILD_ROOT }}/${{ env.RELEASE_FILE }}.tar.gz