From 9334bf03331ff2af5d990f246246211292670b17 Mon Sep 17 00:00:00 2001 From: Stefan Haller Date: Sun, 23 Nov 2025 18:10:59 +0100 Subject: [PATCH] Don't use "HEADLESS" environment variable for running tests It is a bit generic, it seems that users sometimes set it for other reasons, and then they are confused why they don't see anything. Use a more specific name instead. --- pkg/gui/test_mode.go | 2 +- pkg/integration/clients/go_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/gui/test_mode.go b/pkg/gui/test_mode.go index c5014ad729e..ef81e11cb4f 100644 --- a/pkg/gui/test_mode.go +++ b/pkg/gui/test_mode.go @@ -61,5 +61,5 @@ func (gui *Gui) handleTestMode() { } func Headless() bool { - return os.Getenv("HEADLESS") != "" + return os.Getenv("LAZYGIT_HEADLESS") != "" } diff --git a/pkg/integration/clients/go_test.go b/pkg/integration/clients/go_test.go index 8984c759a5e..211e73d2850 100644 --- a/pkg/integration/clients/go_test.go +++ b/pkg/integration/clients/go_test.go @@ -65,7 +65,7 @@ func TestIntegration(t *testing.T) { func runCmdHeadless(cmd *exec.Cmd) (int, error) { cmd.Env = append( cmd.Env, - "HEADLESS=true", + "LAZYGIT_HEADLESS=true", "TERM=xterm", )