Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use github actions #214

Merged
merged 5 commits into from
May 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Build CI

on:
push:
pull_request:
release:
types: [published]

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Set up repository
uses: actions/checkout@v4
with:
fetch-depth: 0
filter: "blob:none"
show-progress: false
submodules: false
- name: Set up compiler
uses: carlosperate/arm-none-eabi-gcc-action@v1
with:
# When changing this update what Windows grabs too!
release: '13.2.Rel1'
- name: Extract version identifier
run: |
echo >> $GITHUB_ENV "UF2_VERSION_BASE=`git describe --dirty --always --tags`"
- name: Build
run: make submodules && make -j$(nproc) all-boards && mv build/drop build/uf2-samdx1-$UF2_VERSION_BASE
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
path: build/uf2-samdx1-${{ env.UF2_VERSION_BASE }}/*
name: uf2-samdx1-${{ env.UF2_VERSION_BASE }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ node_modules
scripts/clean-ifaces/*.plist
.vscode/c_cpp_properties.json
TAGS
dist
28 changes: 0 additions & 28 deletions .travis.yml

This file was deleted.

11 changes: 6 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ SELF_EXECUTABLE_INO=$(BUILD_PATH)/update-$(NAME).ino

SUBMODULES = lib/uf2/README.md

all: $(SUBMODULES) dirs $(EXECUTABLE) $(SELF_EXECUTABLE)
all: submodules dirs $(EXECUTABLE) $(SELF_EXECUTABLE)
submodules: $(SUBMODULES)

r: run
b: burn
Expand Down Expand Up @@ -218,10 +219,10 @@ ifeq ($(CHIP_FAMILY),samd21)
endif

drop-pkg:
mv build/drop build/uf2-samd21-$(UF2_VERSION_BASE)
cp bin-README.md build/uf2-samd21-$(UF2_VERSION_BASE)/README.md
cd build; 7z a uf2-samd21-$(UF2_VERSION_BASE).zip uf2-samd21-$(UF2_VERSION_BASE)
rm -rf build/uf2-samd21-$(UF2_VERSION_BASE)
mv build/drop build/uf2-samdx1-$(UF2_VERSION_BASE)
cp bin-README.md build/uf2-samdx1-$(UF2_VERSION_BASE)/README.md
cd build; 7z a uf2-samdx1-$(UF2_VERSION_BASE).zip uf2-samdx1-$(UF2_VERSION_BASE)
rm -rf build/uf2-samdx1-$(UF2_VERSION_BASE)

all-boards:
for f in `cd boards; ls` ; do "$(MAKE)" BOARD=$$f drop-board || break -1; done
Expand Down