projects
/
silc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
2cbaaaf
)
fix.pl: support for new perl
author
Pekka Riikonen
<priikone@silcnet.org>
Thu, 8 Jan 2009 13:58:57 +0000
(15:58 +0200)
committer
Pekka Riikonen
<priikone@silcnet.org>
Thu, 8 Jan 2009 13:58:57 +0000
(15:58 +0200)
scripts/fix.pl
patch
|
blob
|
history
diff --git
a/scripts/fix.pl
b/scripts/fix.pl
index dca618e6a313f457663ab9157a7805b02b5d580d..8cdaffb148c2cb24ea0f92db6caa44fb3121819f 100755
(executable)
--- a/
scripts/fix.pl
+++ b/
scripts/fix.pl
@@
-1,7
+1,7
@@
#!/usr/bin/perl
# fix.pl 17-Nov-93 Craig Milo Rogers at USC/ISI
#!/usr/bin/perl
# fix.pl 17-Nov-93 Craig Milo Rogers at USC/ISI
-#
+#
# The style guide for RFCs calls for pages to be delimited by the
# sequence <last-non-blank-line><formfeed-line><first-non-blank-line>.
# Unfortunately, NROFF is reluctant to produce output that conforms to
# The style guide for RFCs calls for pages to be delimited by the
# sequence <last-non-blank-line><formfeed-line><first-non-blank-line>.
# Unfortunately, NROFF is reluctant to produce output that conforms to
@@
-24,17
+24,17
@@
#
# When porting this script, please observe the following points:
#
#
# When porting this script, please observe the following points:
#
-# 1) ISI keeps perl in "/local/bin/perl"; your system may keep it
+# 1) ISI keeps perl in "/local/bin/perl"; your system may keep it
# elsewhere.
# 2) On systems with a CRLF end-of-line convention, the "0s below
# may have to be replaced with "^[70s.
# elsewhere.
# 2) On systems with a CRLF end-of-line convention, the "0s below
# may have to be replaced with "^[70s.
-$* = 1; # Enable multiline patterns.
+
#
$* = 1; # Enable multiline patterns.
undef $/; # Read whole files in a single
# gulp.
undef $/; # Read whole files in a single
# gulp.
-
+
while (<>) { # Read the entire input file.
s/FORMFEED(\[Page\s+\d+\])\s+/ \1\n\f\n/g;
s/\f\n$/\f/; # Want bare formfeed at end?
print; # Print the resultant file.
while (<>) { # Read the entire input file.
s/FORMFEED(\[Page\s+\d+\])\s+/ \1\n\f\n/g;
s/\f\n$/\f/; # Want bare formfeed at end?
print; # Print the resultant file.
-}
+}