Skip to content

Commit 574178e

Browse files
authored
cleanup: update files, add workflows
Signed-off-by: K.B.Dharun Krishna <[email protected]>
1 parent cf6cba0 commit 574178e

File tree

5 files changed

+115
-31
lines changed

5 files changed

+115
-31
lines changed

.github/FUNDING.yml

-4
This file was deleted.

.github/workflows/build.yml

+41-25
Original file line numberDiff line numberDiff line change
@@ -1,38 +1,54 @@
1-
name: Build release packages
1+
name: Build
2+
23
on:
3-
release:
4-
types: [published]
5-
workflow_dispatch:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
68
jobs:
7-
build-packages:
8-
runs-on: ubuntu-22.04
9+
build:
10+
runs-on: ubuntu-latest
11+
container:
12+
image: ghcr.io/vanilla-os/pico:main
13+
volumes:
14+
- /proc:/proc
15+
- /:/run/host
16+
options: --privileged -it
17+
918
steps:
10-
- uses: actions/checkout@v2
19+
- uses: actions/checkout@v4
1120

12-
# Misc
13-
# --------------------------------------
1421
- name: Get the version
1522
id: get_version
16-
run: echo ::set-output name=VERSION::$(cat VERSION)
23+
run: echo "{VERSION}={$(cat VERSION)}" >> $GITHUB_OUTPUT
1724

18-
# Dependencies
19-
# --------------------------------------
2025
- name: Install build dependencies
2126
run: |
22-
sudo apt install -y debhelper python3 gettext build-essential desktop-file-utils ninja-build meson libadwaita-1-dev make
27+
apt install -y debhelper python3 gettext build-essential desktop-file-utils ninja-build meson libadwaita-1-dev make libnm-dev libnma-dev libnma-gtk4-dev
2328
24-
# Deb Build
25-
# --------------------------------------
2629
- name: Build .deb package
27-
run: dpkg-buildpackage
30+
run: |
31+
dpkg-buildpackage
32+
mv ../vanilla-first-setup_*.deb .
33+
34+
- name: Calculate and Save Checksums
35+
run: |
36+
sha256sum vanilla-first-setup_*.deb >> checksums.txt
37+
38+
- uses: actions/upload-artifact@v4
39+
with:
40+
name: first-setup
41+
path: |
42+
checksums.txt
43+
vanilla-first-setup_*.deb
2844
29-
# Release packages
30-
# --------------------------------------
31-
- uses: "marvinpinto/action-automatic-releases@latest"
45+
- uses: softprops/action-gh-release@v2
46+
if: github.ref == 'refs/heads/main'
3247
with:
33-
repo_token: "${{ secrets.GITHUB_TOKEN }}"
34-
draft: false
35-
prerelease: false
36-
automatic_release_tag: ${{ steps.get_version.outputs.VERSION }}
37-
title: ${{ steps.get_version.outputs.VERSION }}
38-
files: ../vanilla-first-setup_*.deb
48+
token: "${{ secrets.GITHUB_TOKEN }}"
49+
tag_name: "continuous"
50+
prerelease: true
51+
name: "Continuous Build"
52+
files: |
53+
checksums.txt
54+
vanilla-first-setup_*.deb

.github/workflows/release.yml

+73
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
jobs:
9+
build-artifacts:
10+
runs-on: ubuntu-latest
11+
container:
12+
image: ghcr.io/vanilla-os/pico:main
13+
volumes:
14+
- /proc:/proc
15+
- /:/run/host
16+
options: --privileged -it
17+
permissions:
18+
contents: read
19+
20+
steps:
21+
- uses: actions/checkout@v4
22+
23+
- name: Get the version
24+
id: get_version
25+
run: echo ::set-output name=VERSION::$(cat VERSION)
26+
27+
- name: Install build dependencies
28+
run: |
29+
apt install -y debhelper python3 gettext build-essential desktop-file-utils ninja-build meson libadwaita-1-dev make libnm-dev libnma-dev libnma-gtk4-dev
30+
31+
- name: Build .deb package
32+
run: dpkg-buildpackage
33+
34+
- name: Calculate and Save Checksums
35+
run: |
36+
sha256sum vanilla-first-setup_2.2.0_amd64.deb >> checksums.txt
37+
38+
- uses: actions/upload-artifact@v4
39+
with:
40+
name: first-setup
41+
path: |
42+
checksums.txt
43+
vanilla-first-setup_2.2.0_amd64.deb
44+
45+
release:
46+
runs-on: ubuntu-latest
47+
needs: build-artifacts
48+
permissions:
49+
contents: write # to create and upload assets to releases
50+
attestations: write # to upload assets attestation for build provenance
51+
id-token: write # grant additional permission to attestation action to mint the OIDC token permission
52+
53+
steps:
54+
- name: Checkout
55+
uses: actions/checkout@v4
56+
with:
57+
fetch-depth: 0
58+
59+
- name: Download Artifact
60+
uses: actions/download-artifact@v4
61+
with:
62+
name: first-setup
63+
64+
- name: Create Release
65+
env:
66+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
67+
run: gh release create "${{ github.ref_name }}" --generate-notes *.deb first-setup/checksums.txt
68+
69+
- name: Attest Release Files
70+
id: attest
71+
uses: actions/attest-build-provenance@v1
72+
with:
73+
subject-path: '*.deb, first-setup/*.txt'

README.md

-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
<img src="data/screenshot-1.png">
1313
</div>
1414

15-
1615
## Build
1716

1817
### Dependencies

meson.build

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
project('org.vanillaos.FirstSetup',
2-
version: '2.0.1',
2+
version: '2.2.0',
33
meson_version: '>= 0.59.0',
44
default_options: [ 'warning_level=2',
55
'werror=false',

0 commit comments

Comments
 (0)