mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-12-01 04:34:11 +01:00
fix(scripts): the Linux scripts find the repository from scripts/linux/
The scripts were written for a KDE-only repository root (komorebi-for-kde/, scripts/ one level below it). They now live in scripts/linux/ of the consolidated repository: - run-kde looks for the repository two directories above itself (flake.nix at the root) and no longer knows the komorebi-for-kde/ subdirectory; its comments name nix/linux and docs/linux - vm-mac cd`s two levels up, usage and comments name scripts/linux/vm-mac - sync-e2e-core and scenario-status read nix/linux/tests/vm/lib, and usage lines name the new paths (scenario-status resolves the library with parents[2]) - wsl2-probe.sh names docs/linux/dev/wsl2-probe.md and prints "komorebi (KDE Plasma)" instead of komorebi-for-kde in its report header - compare-gen.py is stale by design: the docstring now says so a second time (layout) and names the new path of COMPARE.md; the logic is not repaired Flake attribute names the scripts call (nix run .#run-kde, .#wsl2-probe, legacyPackages.*.vm.NAME in vm-mac) are left for the one-flake revision. Verified: bash -n and shellcheck -S warning pass on the four shell scripts; the two Python scripts parse (ast); `bash run-kde --dry-run` run from /tmp prints KOMOREBI_REPO as this checkout; `sync-e2e-core --check e2e/lib` prints "in step"; `scenario-status --help` runs. Not run: the VM, vm-mac, wsl2-probe.
This commit is contained in:
1 parent
a7b78cc7e4
commit
1afac08af5
6 files changed
+36
-32
No files matched your search
@@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
# Runs one VM test on a Mac, where the guest is Linux and the host is not.
|
||||
#
|
||||
# scripts/vm-mac NAME [driver arguments]
|
||||
# scripts/linux/vm-mac NAME [driver arguments]
|
||||
#
|
||||
# The guest's closure is built on a Linux builder, copied back, and the test driver then runs
|
||||
# on the Mac under HVF. The driver is run directly, not through `nix build`, because the nix
|
||||
@@ -9,18 +9,18 @@
|
||||
# `.vm/out/NAME`.
|
||||
#
|
||||
# The builder is yours: set KOMOREBI_BUILDER to its store URL (for example
|
||||
# `ssh-ng://builder@localhost`) and, if it needs them, NIX_SSHOPTS. docs/dev/vm-tests.md
|
||||
# `ssh-ng://builder@localhost`) and, if it needs them, NIX_SSHOPTS. docs/linux/dev/vm-tests.md
|
||||
# says what a builder has to be.
|
||||
set -euo pipefail
|
||||
|
||||
name="${1:?usage: scripts/vm-mac NAME [driver arguments]}"
|
||||
name="${1:?usage: scripts/linux/vm-mac NAME [driver arguments]}"
|
||||
shift
|
||||
builder="${KOMOREBI_BUILDER:?set KOMOREBI_BUILDER to the store URL of a Linux builder}"
|
||||
cd "$(dirname "$0")/.."
|
||||
cd "$(dirname "$0")/../.."
|
||||
attr="legacyPackages.aarch64-darwin.vm.$name"
|
||||
test="path:$PWD#$attr"
|
||||
# a git checkout is a flake source without its untracked files (.vm, target); this tree may be the
|
||||
# komorebi-for-kde directory of a bigger repository, whose toplevel is not $PWD
|
||||
# a git checkout is a flake source without its untracked files (.vm, target); the repository may be
|
||||
# a subdirectory of a bigger git repository, whose toplevel is not $PWD
|
||||
if top=$(git rev-parse --show-toplevel 2> /dev/null); then
|
||||
if [ "$top" = "$PWD" ]; then
|
||||
test="git+file://$PWD#$attr"
|
||||
|
||||
Reference in new issue
Block a user