-
Notifications
You must be signed in to change notification settings - Fork 122
65 lines (53 loc) · 1.98 KB
/
linux.yml
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
65
name: Linux build
on:
push:
branches:
- master
- next
- 'next*'
jobs:
qtbuild:
name: Build with Qt
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- run: git fetch --prune --unshallow --tags
- name: Set environment variables
run: |
echo "DATE=`date +%Y%m%d`" >> $GITHUB_ENV
echo "GIT_HASH=`git rev-parse --short HEAD`" >> $GITHUB_ENV
cat $GITHUB_ENV
- name: Display environment variables
run: env | sort
- name: Prepare flatpak build
run: |
set -x
# Install build dependencies
sudo apt-get -y install flatpak-builder
flatpak remote-add --if-not-exists --user flathub https://dl.flathub.org/repo/flathub.flatpakrepo
- name: Build
id: build
run: |
# Create welle-gui Flatpak
flatpak-builder --force-clean --user --install-deps-from=flathub --repo=repo --install builddir io.welle.welle_io.yml
flatpak build-bundle repo welle-io.flatpak io.welle.welle_io --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo
# Prepare publish
mkdir publish
mv welle-io.flatpak publish/"$DATE"_"$GIT_HASH"_Linux_welle-io-x86_64.flatpak
- name: Archive artifacts (welle.io AppImage)
if: always() && steps.create_appimage.outcome == 'success'
uses: actions/upload-artifact@v4
with:
name: welle.io AppImage
path: publish/*.flatpak
if-no-files-found: error
- name: Upload to nightly server
if: always() && steps.create_appimage.outcome == 'success'
uses: dennisameling/ftp-upload-action@v1
with:
server: a2f24.netcup.net # welle-io-nightlies.albrechtloh.de is redirected to here
secure: true
username: ${{ secrets.SFTP_USER }}
password: ${{ secrets.SFTP_PASSWORD }}
local_dir: publish/