-
Notifications
You must be signed in to change notification settings - Fork 50
64 lines (64 loc) · 2.04 KB
/
new_version.yaml
File metadata and controls
64 lines (64 loc) · 2.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
jobs:
release:
permissions:
contents: "write"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout"
uses: "actions/checkout@v6"
with:
fetch-depth: 0
submodules: "recursive"
token: "${{secrets.GIT_PUSH_TOKEN}}"
- if: "github.event.inputs.update == 'true'"
name: "Update submodules"
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git submodule update --remote
if git diff --quiet; then
echo "Submodules are the latest. Nothing to update."
exit
fi
git add .
git commit -m "chore: update submodules"
shell: "bash"
- name: "Set up QEMU Emulation"
uses: "docker/setup-qemu-action@v4"
with:
image: "tonistiigi/binfmt:latest"
- name: "Test"
uses: "devcontainers/ci@v0.3"
with:
push: "never"
runCmd: |
set -euo pipefail
sudo apt-get update
sudo apt-get install --no-install-recommends -y git-buildpackage
export DEBEMAIL="dev@radxa.com"
export DEBFULLNAME='"Radxa Computer Co., Ltd"'
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
make dch
make test deb
- if: "github.event.inputs.release == 'true'"
name: "Push"
run: |
git push
shell: "bash"
name: "Create release"
"on":
workflow_dispatch:
inputs:
release:
default: true
description: "Release new version"
required: true
type: "boolean"
update:
default: false
description: "Update submodule"
required: true
type: "boolean"
permissions: {}
run-name: "${{ inputs.update && 'Update submodule' || '' }}${{ inputs.update && inputs.release && ' & ' || '' }}${{ inputs.release && 'Release new version' }}${{ !inputs.update && !inputs.release && 'Test for new release' || '' }}"