Skip to content

Commit

Permalink
Update CI
Browse files Browse the repository at this point in the history
  • Loading branch information
RadxaYuntian committed Dec 30, 2022
1 parent 1261276 commit 9c464ae
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 6 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Build
on:
workflow_dispatch:
pull_request:
push:

jobs:
release:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
fetch-depth: 0
- name: Test
run: |
make test
- name: Build
run: |
sudo apt-get update
sudo apt-get build-dep --no-install-recommends -y .
make all deb
9 changes: 6 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build & Release
name: Release
on:
workflow_dispatch:
push:
Expand All @@ -22,18 +22,20 @@ jobs:
make all deb
- name: Check if the latest version is releasable
run: |
echo "version=$(dpkg-parsechangelog -S Version)" >> $GITHUB_ENV
version="$(dpkg-parsechangelog -S Version)"
echo "version=$version" >> $GITHUB_ENV
echo "changes<<EOF" >> $GITHUB_ENV
echo '```' >> $GITHUB_ENV
echo "$(dpkg-parsechangelog -S Changes)" >> $GITHUB_ENV
echo '```' >> $GITHUB_ENV
echo "EOF" >> $GITHUB_ENV
if [[ -n "$(git tag -l "$(dpkg-parsechangelog -S Version)")" ]]
if [[ -n "$(git tag -l "$version")" ]]
then
echo "distro=UNRELEASED" >> $GITHUB_ENV
else
echo "distro=$(dpkg-parsechangelog -S Distribution)" >> $GITHUB_ENV
fi
echo "$version" > VERSION
- name: Release
if: env.distro != 'UNRELEASED'
uses: softprops/action-gh-release@v1
Expand All @@ -45,6 +47,7 @@ jobs:
draft: false
files: |
../*.deb
VERSION
- name: Append changelog
if: env.distro != 'UNRELEASED'
uses: softprops/action-gh-release@v1
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/.vscode*
/overlay
/overlay
/VERSION
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -95,4 +95,4 @@ dch: debian/changelog

.PHONY: deb
deb: debian
debuild --no-sign
debuild --no-lintian --lintian-hook "lintian --fail-on error,warning,info --suppress-tags bad-distribution-in-changes-file -- %p_%v_*.changes" --no-sign
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# Small bug number is very probable for us.
rsetup: improbable-bug-number-in-closes
rsetup: improbable-bug-number-in-closes
2 changes: 2 additions & 0 deletions debian/rsetup.service → debian/service
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
[Unit]
Description=rsetup configuration service
Documentation=https://github.com/radxa-pkg/rsetup/

[Service]
Type=simple
ExecStart=/usr/bin/rsetup __on_boot

[Install]
WantedBy=multi-user.target

0 comments on commit 9c464ae

Please sign in to comment.