-
Notifications
You must be signed in to change notification settings - Fork 1
76 lines (61 loc) · 2.25 KB
/
main.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
66
67
68
69
70
71
72
73
74
75
76
name: CI
# This workflow will run for any pull request or pushed commit
on: [push, pull_request]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# build from source. separated out this step from build as flatpak as build
# as flatpak might include longer steps when compiling external modules
build:
name: Build
runs-on: ubuntu-latest
container:
image: elementary/docker:unstable
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install Dependencies
env:
dependency_packages: libvala-dev valac meson libgtk-3-dev libgranite-dev libclutter-gst-3.0-dev libclutter-gtk-1.0-dev libgstreamer1.0-dev appstream
run: apt-get update && apt-get -y install ${dependency_packages}
- name: Build
run: |
meson build --prefix=/usr
ninja -C build
ninja -C build install
# build a flatpak
flatpak:
name: Flatpak
runs-on: ubuntu-latest
# no point in running packaging if normal build has failed
needs: build
# This job runs in a special container designed for building Flatpaks for AppCenter
container:
image: ghcr.io/elementary/flatpak-platform/runtime:6
options: --privileged
steps:
- name: Checkout
# Checks-out your repository under $GITHUB_WORKSPACE, so the job can access it
uses: actions/checkout@v2
# Builds your flatpak manifest using the Flatpak Builder action
- name: Flatpak
uses: bilelmoussaoui/flatpak-github-actions/flatpak-builder@v3
with:
# This is the name of the Bundle file we're building
bundle: Trimmer.flatpak
manifest-path: com.github.phoneybadger.trimmer.yml
run-tests: false
# These lines specify the location of the elementary Runtime and Sdk
repository-name: appcenter
repository-url: https://flatpak.elementary.io/repo.flatpakrepo
cache-key: "flatpak-builder-${{ github.sha }}"
# check for code style errors
lint:
name: Lint
runs-on: ubuntu-latest
container:
image: valalang/lint
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Lint
run: io.elementary.vala-lint -d .