vmix.nix/lib/images/windows
Git Sagar 97fdbce6d0 windows images: stop a non-matching display glob from poisoning the build env
Image builds have been dying with "Argument list too long" from sed, mktemp
and timeout alike -- commands whose argv is trivial, which is the tell that it
was the environment that had grown, not the arguments.

The X11 forwarding hint is looked up with `ls -t /tmp/.vmix-display-* | head -1`.
Under nullglob a non-matching pattern is removed from the command line rather
than passed through literally, so `ls -t` runs with no arguments at all and
lists the working directory instead. In a nix build that directory is the
build tree, whose newest file is nix's own env-vars dump. The result is that
VMIX_DF becomes "env-vars", the SDL branch is taken on a machine with no X at
all, and DISPLAY is exported with a slice of the env dump inside it. From that
line onward every exec in the build fails with E2BIG.

find does the same lookup without depending on how the shell treats an
unmatched pattern, and -type f keeps a stray directory out of it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0117qMyjpuXsjpVAcpJbFD8g
2026-09-10 00:06:07 -03:00
..
drivers sync with labv2.nix + standalone flake with toDisk app 2026-05-23 19:18:10 -03:00
helpers windows images: stop a non-matching display glob from poisoning the build env 2026-09-10 00:06:07 -03:00
templates generalize: writeFilter, putting UWF's overlay on the data volume 2026-09-09 23:22:40 -03:00
win10 laptop image tiers, devshell, partition preserve, cleanup 2026-05-24 13:32:18 -03:00
win11 laptop image tiers, devshell, partition preserve, cleanup 2026-05-24 13:32:18 -03:00
default.nix sync with labv2.nix + standalone flake with toDisk app 2026-05-23 19:18:10 -03:00