steps:
- uses: actions/checkout@v3
- - name: Update systemd-analyze
- shell: bash
- working-directory: ${{ github.action_path }}
- run: |
- echo "deb-src http://archive.ubuntu.com/ubuntu/ $(lsb_release -cs) main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list
- sudo apt-get update
- sudo apt-get build-dep systemd
+ - name: Update systemd-analyze
+ run: |
+ echo "deb-src http://archive.ubuntu.com/ubuntu/ $(lsb_release -cs) main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list
+ sudo apt-get update
+ sudo apt-get build-dep systemd
- git clone https://github.com/systemd/systemd --depth=1
- meson systemd/build systemd
+ git clone https://github.com/systemd/systemd --depth=1
+ meson setup systemd/build systemd
- ninja -C systemd/build systemd-analyze
+ ninja -C systemd/build systemd-analyze
- sudo ln -svf $PWD/systemd/build/systemd-analyze /usr/bin/systemd-analyze
- systemd-analyze --version
+ sudo ln -svf $PWD/systemd/build/systemd-analyze /usr/bin/systemd-analyze
+ systemd-analyze --version
- name: Install
run: |
run: python3 -m mypy mkosi/ tests/
- name: Type Checking (pyright)
- run: pyright .
+ run: pyright mkosi/ tests/
- name: Unit Tests
run: python3 -m pytest -sv tests
- name: Test shell scripts
run: |
sudo apt-get update && sudo apt-get install --no-install-recommends shellcheck
- bash -c 'shopt -s globstar; shellcheck **/*.sh'
+ bash -c 'shopt -s globstar; shellcheck bin/mkosi tools/*.sh'
integration-test:
runs-on: ubuntu-22.04
sudo apt-get install libfdisk-dev
git clone https://github.com/systemd/systemd --depth=1
- meson systemd/build systemd -Drepart=true -Defi=true -Dbootloader=true
+ meson setup systemd/build systemd -Drepart=true -Defi=true -Dbootloader=true -Dukify=true
BINARIES=(
bootctl
# SPDX-License-Identifier: LGPL-2.1+
-import argparse
import base64
import contextlib
import crypt
if f and not args.force:
die(f"{f} already exists",
hint=("To generate new secure boot keys, "
- f"first remove mkosi.secure-boot.key and mkosi.secure-boot.crt"))
+ "first remove mkosi.secure-boot.key and mkosi.secure-boot.crt"))
log_step(f"Generating secure boot keys rsa:{keylength} for CN {cn!r}.")
logging.info(
)
)
- conf = parse([])
+ conf = parse([])[1]
assert "testpkg1" in conf.packages
if dist1 == dist2:
assert "testpkg2" in conf.packages
)
)
- conf = parse([])
+ conf = parse([])[1]
assert "testpkg1" in conf.packages
if release1 == release2:
assert "testpkg2" in conf.packages
)
)
- conf = parse([])
+ conf = parse([])[1]
assert "testpkg1" in conf.packages
if image1 == image2:
assert "testpkg2" in conf.packages
)
)
- conf = parse([])
+ conf = parse([])[1]
assert ("testpkg1" in conf.packages) == opfunc(123, version)
assert ("testpkg2" in conf.packages) == opfunc(123, version)
assert "testpkg3" not in conf.packages