perl 4.0.00: (no release announcement available)
[p5sagit/p5-mst-13.2.git] / x2p / s2p.man
1 .rn '' }`
2 ''' $Header: s2p.man,v 4.0 91/03/20 01:58:07 lwall Locked $
3 ''' 
4 ''' $Log:       s2p.man,v $
5 ''' Revision 4.0  91/03/20  01:58:07  lwall
6 ''' 4.0 baseline.
7 ''' 
8 ''' Revision 3.0  89/10/18  15:35:09  lwall
9 ''' 3.0 baseline
10 ''' 
11 ''' Revision 2.0  88/06/05  00:15:59  root
12 ''' Baseline version 2.0.
13 ''' 
14 ''' 
15 .de Sh
16 .br
17 .ne 5
18 .PP
19 \fB\\$1\fR
20 .PP
21 ..
22 .de Sp
23 .if t .sp .5v
24 .if n .sp
25 ..
26 .de Ip
27 .br
28 .ie \\n.$>=3 .ne \\$3
29 .el .ne 3
30 .IP "\\$1" \\$2
31 ..
32 '''
33 '''     Set up \*(-- to give an unbreakable dash;
34 '''     string Tr holds user defined translation string.
35 '''     Bell System Logo is used as a dummy character.
36 '''
37 .tr \(*W-|\(bv\*(Tr
38 .ie n \{\
39 .ds -- \(*W-
40 .if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
41 .if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
42 .ds L" ""
43 .ds R" ""
44 .ds L' '
45 .ds R' '
46 'br\}
47 .el\{\
48 .ds -- \(em\|
49 .tr \*(Tr
50 .ds L" ``
51 .ds R" ''
52 .ds L' `
53 .ds R' '
54 'br\}
55 .TH S2P 1 NEW
56 .SH NAME
57 s2p - Sed to Perl translator
58 .SH SYNOPSIS
59 .B s2p [options] filename
60 .SH DESCRIPTION
61 .I S2p
62 takes a sed script specified on the command line (or from standard input)
63 and produces a comparable
64 .I perl
65 script on the standard output.
66 .Sh "Options"
67 Options include:
68 .TP 5
69 .B \-D<number>
70 sets debugging flags.
71 .TP 5
72 .B \-n
73 specifies that this sed script was always invoked with a sed -n.
74 Otherwise a switch parser is prepended to the front of the script.
75 .TP 5
76 .B \-p
77 specifies that this sed script was never invoked with a sed -n.
78 Otherwise a switch parser is prepended to the front of the script.
79 .Sh "Considerations"
80 The perl script produced looks very sed-ish, and there may very well be
81 better ways to express what you want to do in perl.
82 For instance, s2p does not make any use of the split operator, but you might
83 want to.
84 .PP
85 The perl script you end up with may be either faster or slower than the original
86 sed script.
87 If you're only interested in speed you'll just have to try it both ways.
88 Of course, if you want to do something sed doesn't do, you have no choice.
89 .SH ENVIRONMENT
90 S2p uses no environment variables.
91 .SH AUTHOR
92 Larry Wall <lwall@jpl-devvax.Jpl.Nasa.Gov>
93 .SH FILES
94 .SH SEE ALSO
95 perl    The perl compiler/interpreter
96 .br
97 a2p     awk to perl translator
98 .SH DIAGNOSTICS
99 .SH BUGS
100 .rn }` ''