]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
rename.1: describe interactive mode
authorG.raud Meyer <graud@gmx.com>
Mon, 2 Apr 2018 13:32:44 +0000 (15:32 +0200)
committerG.raud Meyer <graud@gmx.com>
Mon, 9 Apr 2018 15:21:16 +0000 (17:21 +0200)
misc-utils/rename.1

index fb8d4f621e1432466f260b879d54bab2399b56eb..1f6047920322118eae66ec6db2fbfb7787b7e57c 100644 (file)
@@ -83,6 +83,19 @@ permission to rewrite file names, the command will perform the action without
 any questions.  For example, the result can be quite drastic when the command
 is run as root in the /lib directory.  Always make a backup before running the
 command, unless you truly know what you are doing.
+.SH INTERACTIVE MODE
+As most standard utilities rename can be used with a terminal device (tty in
+short) in canonical mode, where the line is buffered by the tty and you press
+ENTER to validate the user input.  If you put your tty in cbreak mode however,
+rename requires only a single key press to answer the prompt.  To set cbreak
+mode, run for example:
+.RS
+.PP
+.nf
+sh -c 'stty -icanon min 1; "$0" "$@"; stty icanon' rename -i from to files
+.fi
+.PP
+.RE
 .SH "EXIT STATUS"
 .RS
 .PD 0