From: Brendan O'Dea Date: Sun, 28 Sep 2003 23:23:34 +0000 (+1000) Subject: pod/perlrun.pod: no space after -i allowed X-Git-Tag: accepted/trunk/20130322.191538~22904 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ddffceb7d688de00c74f6c81d16019f39be53dc8;p=platform%2Fupstream%2Fperl.git pod/perlrun.pod: no space after -i allowed Message-ID: <20030928132334.GA29499@londo.c47.org> p4raw-id: //depot/perl@21385 --- diff --git a/pod/perlrun.pod b/pod/perlrun.pod index 81d4749..91e1643 100644 --- a/pod/perlrun.pod +++ b/pod/perlrun.pod @@ -451,20 +451,20 @@ as: This allows you to add a prefix to the backup file, instead of (or in addition to) a suffix: - $ perl -pi 'orig_*' -e 's/bar/baz/' fileA # backup to 'orig_fileA' + $ perl -pi'orig_*' -e 's/bar/baz/' fileA # backup to 'orig_fileA' Or even to place backup copies of the original files into another directory (provided the directory already exists): - $ perl -pi 'old/*.orig' -e 's/bar/baz/' fileA # backup to 'old/fileA.orig' + $ perl -pi'old/*.orig' -e 's/bar/baz/' fileA # backup to 'old/fileA.orig' These sets of one-liners are equivalent: $ perl -pi -e 's/bar/baz/' fileA # overwrite current file - $ perl -pi '*' -e 's/bar/baz/' fileA # overwrite current file + $ perl -pi'*' -e 's/bar/baz/' fileA # overwrite current file - $ perl -pi '.orig' -e 's/bar/baz/' fileA # backup to 'fileA.orig' - $ perl -pi '*.orig' -e 's/bar/baz/' fileA # backup to 'fileA.orig' + $ perl -pi'.orig' -e 's/bar/baz/' fileA # backup to 'fileA.orig' + $ perl -pi'*.orig' -e 's/bar/baz/' fileA # backup to 'fileA.orig' From the shell, saying