From 3a7757f1fdc4ae30d7ce177792be437a7a5ca52f Mon Sep 17 00:00:00 2001 From: Winter Date: Thu, 2 Mar 2023 21:27:10 -0500 Subject: environment: Clear 'TERM' when checking environment. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * guix/scripts/environment.scm (child-shell-environment): Set 'TERM' to the empty string. Co-authored-by: Ludovic Courtès --- guix/scripts/environment.scm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm index 33a76abff3..a4939ea63c 100644 --- a/guix/scripts/environment.scm +++ b/guix/scripts/environment.scm @@ -514,6 +514,11 @@ by running 'set' in the shell." (catch #t (lambda () (load-profile profile manifest #:pure? #t) + + ;; Mark the terminal as "unknown" do avoid ANSI escape codes such + ;; as bracketed paste that would mess up the output of the script. + (setenv "TERM" "") + (setenv "GUIX_ENVIRONMENT" profile) (close-fdes controller) (login-tty inferior) -- cgit 1.4.1