Skip to content

feat: Use AudioPlayers instead of canberra-gtk-play #1214

feat: Use AudioPlayers instead of canberra-gtk-play

feat: Use AudioPlayers instead of canberra-gtk-play #1214

Workflow file for this run

name: CI
on:
push:
branches:
- main
- archive/main
pull_request:
branches:
- main
- archive/main
workflow_dispatch:
jobs:
flutter-analyze:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- run: melos analyze
bootstrap:
runs-on: ubuntu-22.04
strategy:
matrix:
target:
- ubuntu_bootstrap_test.dart
- screenshot_test.dart
fail-fast: false
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- run: |
sudo apt update
sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip
sudo apt install -y dbus-x11 network-manager upower
sudo apt install -y libunwind-dev libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev
make install_deps
- run: |
sudo loginctl enable-linger $USER
sudo systemctl start user@$UID.service
echo "XDG_RUNTIME_DIR=/run/user/$UID" >> $GITHUB_ENV
# write any setting to force-start dconf.service (via xvfb because dbus-launch needs a display)
xvfb-run -a gsettings set org.gnome.desktop.interface color-scheme "'default'"
- run: xvfb-run -a -s '-screen 0 1024x768x24 +extension GLX' flutter test integration_test/${{matrix.target}}
working-directory: packages/ubuntu_bootstrap
env:
SUBIQUITY_REPLAY_TIMESCALE: 100
flutter-format:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- run: melos format
init:
runs-on: ubuntu-22.04
strategy:
matrix:
target:
- ubuntu_init_test.dart
- screenshot_test.dart
fail-fast: false
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- run: |
sudo apt update
sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip
sudo apt install -y libunwind-dev libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev
- run: xvfb-run -a -s '-screen 0 1024x768x24 +extension GLX' flutter test integration_test/${{matrix.target}}
working-directory: packages/ubuntu_init
flutter-mocks:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- run: melos generate
- name: Check for outdated mocks
if: github.event_name == 'pull_request'
run: ./.github/scripts/check-outdated-files.sh
- name: Create PR
if: github.event_name == 'push'
uses: peter-evans/create-pull-request@v6
with:
add-paths: '**/*.mocks.dart'
title: 'chore: regenerate mocks'
commit-message: 'chore: regenerate mocks'
branch: create-pull-request/mocks
delete-branch: true
l10n:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- run: melos gen-l10n
- name: Check for outdated l10n
if: github.event_name == 'pull_request'
run: ./.github/scripts/check-outdated-files.sh
- name: Create PR
if: github.event_name == 'push'
uses: peter-evans/create-pull-request@v6
with:
add-paths: '**/l10n/*.dart'
title: 'chore: regenerate l10n'
commit-message: 'chore: regenerate l10n'
branch: create-pull-request/l10n
delete-branch: true
flutter-tests:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: asdf-vm/actions/install@v3
- uses: bluefireteam/melos-action@v2
- name: Install dependencies
run: |
sudo apt update && sudo apt install lcov
make install_deps
- name: Setup environment
run: |
sudo loginctl enable-linger $USER
sudo systemctl start user@$UID.service
echo "XDG_RUNTIME_DIR=/run/user/$UID" >> $GITHUB_ENV
- run: melos coverage
- uses: codecov/codecov-action@v4
with:
flags: UI
token: ${{secrets.CODECOV_TOKEN}}
go-sanity:
name: "Go: Code sanity"
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: |
sudo apt-get update
sudo apt install -y libgtk-3-dev
- uses: actions/checkout@v4
- name: Go code sanity check
uses: canonical/desktop-engineering/gh-actions/go/code-sanity@main
with:
golangci-lint-configfile: ".golangci.yaml"
tools-directory: "./provd/tools"
working-directory: "./provd"
- name: Build cmd/provd
run: |
set -eu
cd provd
go build ./cmd/provd
go-tests:
name: "Go: Tests"
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: |
sudo apt-get update
sudo apt install -y libgtk-3-dev
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: "./provd/go.mod"
- name: Run tests
run: |
set -eu
cd provd
go test -coverpkg=./... -coverprofile=/tmp/coverage.out -covermode=set ./... -shuffle=on
- name: Run tests (with race detector)
run: |
cd provd
go test -race ./...
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
file: /tmp/coverage.out
flags: provd
token: ${{secrets.CODECOV_TOKEN}}