texinfo-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[no subject]


From: Gavin D. Smith
Date: Fri, 10 Nov 2023 14:32:33 -0500 (EST)

branch: master
commit e7d138ce12aba82486cc2d9172912af5ecf82625
Author: Gavin Smith <gavinsmith0123@gmail.com>
AuthorDate: Fri Nov 10 19:32:24 2023 +0000

    * util/texi2dvi (move_to_dest): When --output is given, report
    that a file was moved successfully.  Error out if the file could
    not be moved.
    
    Jonathan Dushoff <dushoff@mcmaster.ca> reported that the output
    with the --output option was confusing, as TeX would not print
    the name of the final location.
---
 ChangeLog     | 10 ++++++++++
 util/texi2dvi |  8 +++++++-
 2 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 8df76f623a..7762fbe16c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2023-11-10  Gavin Smith <gavinsmith0123@gmail.com>
+
+       * util/texi2dvi (move_to_dest): When --output is given, report
+       that a file was moved successfully.  Error out if the file could
+       not be moved.
+
+       Jonathan Dushoff <dushoff@mcmaster.ca> reported that the output
+       with the --output option was confusing, as TeX would not print
+       the name of the final location.
+
 2023-11-10  Gavin Smith <gavinsmith0123@gmail.com>
 
        * util/texi2dvi (move_to_dest): Rearrange code slightly
diff --git a/util/texi2dvi b/util/texi2dvi
index 8799c42bdc..b9757b9ddd 100755
--- a/util/texi2dvi
+++ b/util/texi2dvi
@@ -590,7 +590,13 @@ move_to_dest ()
   then
     verbose "Moving $1 to $dest"
     rm -f "$dest"
-    mv "$1" "$dest"
+    if mv "$1" "$dest" ; then
+       # For --output, report that the file was moved, as TeX has just
+       # reported that it wrote output at the original location.
+       test z"$oname" != z && echo "Moved $1 to $dest"
+    else
+       error 1 "Could not move $1 to $dest"
+    fi
   fi
 }
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]