[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[automake-commit] branch master updated: install-sh: do not redundantly
From: |
Karl Berry |
Subject: |
[automake-commit] branch master updated: install-sh: do not redundantly specify -f to rm. |
Date: |
Tue, 10 Nov 2020 20:48:48 -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=5c8d6e25d70ff54b2118c1fc9bfb1a05dbd1de29
The following commit(s) were added to refs/heads/master by this push:
new 5c8d6e2 install-sh: do not redundantly specify -f to rm.
5c8d6e2 is described below
commit 5c8d6e25d70ff54b2118c1fc9bfb1a05dbd1de29
Author: Karl Berry <karl@freefriends.org>
AuthorDate: Tue Nov 10 17:48:35 2020 -0800
install-sh: do not redundantly specify -f to rm.
* lib/install-sh: do not redundantly specify -f to rm.
Mention implication for RMPROG in the --help message.
Original patch sent by Julien Elie:
https://lists.gnu.org/archive/html/automake-patches/2018-03/msg00005.html
* NEWS: mention this.
---
NEWS | 3 +++
lib/install-sh | 7 +++++--
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/NEWS b/NEWS
index 010cd37..c7d02d6 100644
--- a/NEWS
+++ b/NEWS
@@ -92,6 +92,9 @@ New in ?.?.?:
* Miscellaneous changes
+ - install-sh no longer unconditionally uses -f when rm is overridden
+ by RMPROG.
+
- Removed function up_to_date_p in lib/Automake/FileUtils.pm.
We believe this function is completely unused.
diff --git a/lib/install-sh b/lib/install-sh
index b34a8fc..2915ff0 100755
--- a/lib/install-sh
+++ b/lib/install-sh
@@ -115,6 +115,9 @@ Options:
Environment variables override the default commands:
CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG
RMPROG STRIPPROG
+
+By default, rm is invoked with -f; when overridden with RMPROG,
+it's up to you to specify -f if you want it.
"
while test $# -ne 0; do
@@ -487,9 +490,9 @@ do
# file should still install successfully.
{
test ! -f "$dst" ||
- $doit $rmcmd -f "$dst" 2>/dev/null ||
+ $doit $rmcmd "$dst" 2>/dev/null ||
{ $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
- { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
+ { $doit $rmcmd "$rmtmp" 2>/dev/null; :; }
} ||
{ echo "$0: cannot unlink or rename $dst" >&2
(exit 1); exit 1
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [automake-commit] branch master updated: install-sh: do not redundantly specify -f to rm.,
Karl Berry <=