1
0
Fork 0
InfiniTime/.github/workflows/main.yml
Jean-François Milants 831f93cd92 The main build workflow for GitHub Actions now uses the infinitime-build docker image to build the firmware. This allows to avoid the duplication of the build logic in Docker and Github workflow format.
The Dockerfile has been slightly adapted (remove the USER instructions). Docker images are now published in DockerHub (jf002/infinitime-build).
2022-05-26 11:35:25 +02:00

50 lines
1.6 KiB
YAML

# GitHub Actions Workflow to build FreeRTOS Firmware for PineTime Smart Watch
# See https://lupyuen.github.io/pinetime-rust-mynewt/articles/cloud
# Based on https://github.com/JF002/InfiniTime/blob/master/doc/buildAndProgram.md
# and https://github.com/JF002/InfiniTime/blob/master/bootloader/README.md
# Name of this Workflow
name: Build PineTime Firmware
# When to run this Workflow...
on:
# Run this Workflow when files are updated (Pushed) in the "master" and "develop" Branch
push:
branches: [ master, develop ]
# Also run this Workflow when a Pull Request is created or updated in the "master" and "develop" Branch
pull_request:
branches: [ master, develop ]
# Steps to run for the Workflow
jobs:
build:
runs-on: ubuntu-latest
container:
image: jf002/infinitime-build
steps:
- name: Workaround permission issues
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: Checkout source files
uses: actions/checkout@v2
with:
submodules: recursive
- name: Build
shell: bash
env:
SOURCES_DIR: .
run: |
/opt/build.sh all
- name: Upload DFU artifacts
uses: actions/upload-artifact@v2
with:
name: InfiniTime DFU file
path: |
./build/output/pinetime-mcuboot-app-dfu-*.zip
- name: Upload MCUBoot image artifacts
uses: actions/upload-artifact@v2
with:
name: InfiniTime MCUBoot image file
path: |
./build/output/pinetime-mcuboot-app-image-*.bin