screen-lock: recognise the colour build by its version scheme; its version line never says color

This commit is contained in:
jochen
2026-10-04 17:07:40 +02:00
parent 5443223842
commit ba96c59c50
3 changed files with 4 additions and 3 deletions
@@ -38,7 +38,7 @@ func TestTheColourBuildIsKeptWithAFallbackAndXscreensaverGoes(t *testing.T) {
c := wrapper["content"].(string)
// The colour build's options only once it has said it is the colour build: the distribution's
// i3lock refuses an option it does not know, and the screen would not lock at all.
check := strings.Index(c, "i3lock --version 2>&1 | grep -qi color")
check := strings.Index(c, `i3lock --version 2>&1 | grep -qE '[0-9]\.c\.[0-9]'`)
fallback := strings.Index(c, "\nelse\n")
for _, colourOnly := range []string{"--ring-color", "--blur", "--clock", "--indicator", "--time-str"} {
at := strings.Index(c, colourOnly)