1

This is a quote from the rename man page:

   For example, to rename all files matching "*.bak" to strip the
   extension, you might say

         rename 's/\e.bak$//' *.bak

Why is there a \e?

The command doesn't seem to work, whereas the simpler command rename 's/\.bak$//' *.bak does the job. Could it be a mistake in the documentation ?

PiRK
  • 893
  • 3
  • 9
  • 24
  • I don't see any `\e`: http://www.unix.com/man-page/linux/1/rename/ – choroba Apr 20 '16 at 14:27
  • You're right. It appears to be on the 1P (POSIX) man page only: http://man.foreach.site/en/1p/file-rename – PiRK Apr 20 '16 at 14:40
  • Is this the Perl version of rename? http://stackoverflow.com/questions/4509485/linux-remove-file-extensions-for-multiple-files – Quinn Apr 20 '16 at 14:49
  • Probably. The doc mentions perl quite a few times. – PiRK Apr 21 '16 at 07:15
  • It's not only on the 1P page: http://man.foreach.site/en/1/rename I see it on the "updated 2014-05-05" version of man page, but not on the older "2011-08-10" version. My Debian 8 Jessie distribution has the `\e` in the man page. – PiRK Apr 21 '16 at 07:19

0 Answers0