Skip to content

Commit

Permalink
Merge pull request #3 from Psynosaur/main
Browse files Browse the repository at this point in the history
CI refactor
  • Loading branch information
F5OEO committed Feb 3, 2024
2 parents cb804ba + 1d9b9ac commit 33dd477
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 15 deletions.
73 changes: 59 additions & 14 deletions .github/workflows/ci-build.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,35 @@
on:
push:
tags:
- '*'
workflow_dispatch:
inputs:
logLevel:
description: 'Log level'
required: true
default: 'warning'
type: choice
options:
- info
- warning
- debug
version:
description: 'Provide release tag, eg. 0.5.4'
type: string
required: true

env:
VERSION: ${{ inputs.version }}
jobs:
build-x86_64:
runs-on: self-hosted
# runs-on: self-hosted
runs-on: ubuntu-latest
# environment: plutosdr-fw-ci
permissions: write-all

steps:
- uses: actions/checkout@v4.1.1
with:
clean: false
submodules: recursive

- name: Install dependencies
shell: bash
run: |
Expand All @@ -19,23 +41,46 @@ jobs:
zip unzip dfu-util fakeroot u-boot-tools device-tree-compiler mtools \
bison flex libncurses5-dev libssl-dev bc cpio rsync cmake \
libgtk-3-0 xz-utils libgmp-dev libmpc-dev bootgen-xlnx
- name: Cache toolchain
id: cache-toolchain
uses: actions/cache@v4
with:
path: /home/runner/work/plutosdr-fw/plutosdr-fw/buildroot
key: fw-cache-toolchain

- name: Cache linux
id: cache-linux
uses: actions/cache@v4
with:
path: /home/runner/work/plutosdr-fw/plutosdr-fw/linux
key: fw-cache-linux

- name: Checkout
shell: bash
- name: Cache u-boot-xlnx
id: cache-u-boot-xlnx
uses: actions/cache@v4
with:
path: /home/runner/work/plutosdr-fw/plutosdr-fw/u-boot-xlnx
key: fw-cache-u-boot-xlnx

- if: ${{ steps.cache-toolchain.outputs.cache-hit != 'true' }}
name: Build PlutoDatvFirmware - no cache found
run: |
git clone --recursive --depth 1 https://github.com/F5OEO/plutosdr-fw
make
TARGET=plutoplus make
TARGET=e200 make
- name: Build PlutoDatvFirmware
shell: bash
- name: cache found
run: |
cd plutosdr-fw && make && TARGET=plutoplus make && TARGET=e200 make
make
TARGET=plutoplus make
TARGET=e200 make
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: PlutoDVB2_${{ github.ref_name }}
title: Release ${{ github.ref_name }}
automatic_release_tag: PlutoDVB2_${{ inputs.version }}
title: Release ${{ inputs.version }}
prerelease: false
files: |
plutosdr-fw/Release/**.zip
Release/**.zip
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ NCORES = $(shell grep -c ^processor /proc/cpuinfo)
VIVADO_SETTINGS ?= /opt/Xilinx/Vivado/$(VIVADO_VERSION)/settings64.sh
VSUBDIRS = maia-sdr buildroot linux u-boot-xlnx

VERSION=$(shell git describe --abbrev=4 --always --tags)
#VERSION=$(shell git describe --abbrev=4 --always --tags)
PATCH=$(shell cd datv && ./applypatch.sh )
$(shell git log --pretty=format:"%h - %ad : %s" > datv/board/pluto/overlay/root/fwhistory.txt)
#LATEST_TAG=$(shell git describe --abbrev=0 --tags)
Expand Down

0 comments on commit 33dd477

Please sign in to comment.