[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[automake-commit] branch master updated: test: elide leading spaces with
From: |
Karl Berry |
Subject: |
[automake-commit] branch master updated: test: elide leading spaces within case for macOS sh. |
Date: |
Mon, 29 Jan 2024 17:16:15 -0500 |
This is an automated email from the git hooks/post-receive script.
karl pushed a commit to branch master
in repository automake.
View the commit online:
https://git.savannah.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=c354194e691fac341c7416be29eca2b25a0a0e4a
The following commit(s) were added to refs/heads/master by this push:
new c354194e6 test: elide leading spaces within case for macOS sh.
c354194e6 is described below
commit c354194e691fac341c7416be29eca2b25a0a0e4a
Author: Karl Berry <karl@freefriends.org>
AuthorDate: Mon Jan 29 14:16:01 2024 -0800
test: elide leading spaces within case for macOS sh.
Yet another fix in https://bugs.gnu.org/68119.
* t/py-compile-basedir.sh: sed away the leading spaces
from wc -l output within the case statement.
---
t/py-compile-basedir.sh | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/t/py-compile-basedir.sh b/t/py-compile-basedir.sh
index 7ccb8e11c..b9bbb3913 100644
--- a/t/py-compile-basedir.sh
+++ b/t/py-compile-basedir.sh
@@ -42,8 +42,13 @@ for d in foo foo/bar "$(pwd)/foo" . .. ../foo ''; do
py_installed "$d2/$f.pyc"
py_installed "$d2/sub/$f.pyc"
files=$(find "$d2" | grep '\.py[co]$')
- # with new-enough Python3, there are six files.
- case $(echo "$files" | wc -l) in 4|6) ;; *) false;; esac
+ #
+ # 1) With new-enough Python3, there are six files.
+ #
+ # 2) We have to elide the leading spaces from the wc output
+ # for the sake of the macOS shell.
+ # https://debbugs.gnu.org/cgi/bugreport.cgi?bug=68119#4
+ case $(echo "$files" | wc -l | sed 's/^ *//') in 4|6) ;; *) false;; esac
case $d2 in
.|..) rm -f $files;;
*) rm -rf "$d2";;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [automake-commit] branch master updated: test: elide leading spaces within case for macOS sh.,
Karl Berry <=