You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/dev-vcs/rcs/files/rcs-5.10.0-test-t808.patch

33 lines
895 B

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

https://git.savannah.gnu.org/cgit/rcs.git/commit/?h=p&id=5df4567e69fc7f46d14cfbf396525c3d05bcf970
https://bugs.gentoo.org/820230
From: Thien-Thi Nguyen <ttn@gnu.org>
Date: Sat, 24 Oct 2020 19:14:26 -0400
Subject: [v] Try to handle whoami(1) returning no info.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* tests/t808 (user): If whoami(1) returns no info, no longer error out.
Instead, jam a value, and set env vars LOGNAME and USER, as well.
--- a/tests/t808
+++ b/tests/t808
@@ -24,8 +24,14 @@ rerr=$wd/rerr
user=`whoami`
-test "$user" \
- || problem 'far out, man ... whoami failed!'
+if ! test "$user" ; then
+ : 'far out, man ... whoami failed!'
+ user=jrluser
+ USER=$user
+ export USER
+ LOGNAME=$user
+ export LOGNAME
+fi
must 'sed -e s/ttn/trulynobody/g \
-e s/zurg/$user/g \
cgit v1.2.1