1 From: A. Costa <agcosta@gis.net>
5 doc/bbe.1 | 38 +++++++++++++++++++-------------------
6 1 file changed, 19 insertions(+), 19 deletions(-)
11 Add the COMMAND to the commands to be executed.
13 .BR \-f ", " \-\-file=\fIscript\-file\fP
14 -Add the contest of script\-file to commands.
15 +Add the contents of script\-file to commands.
17 .BR \-o ", " \-\-output=\fIname\fP
18 Write output to \fIname\fP instead of standard output.
20 String \fIstart\fP starts \fIM\fR bytes long block.
23 -String \fIstart\fP starts the block and block ends to string \fIstop\fR.
24 +String \fIstart\fP starts the block and block ends at string \fIstop\fR.
27 -String \fIstart\fR starts the block and block will end at next occurence of \fIstart\fR. Only the first \fIstart\fR is included to the block.
28 +String \fIstart\fR starts the block and block will end at next occurrence of \fIstart\fR. Only the first \fIstart\fR is included to the block.
31 Block starts at the beginning of input stream (or at the end of previous block) and ends at the next occurrence of \fIstop\fR. String \fIstop\fR will be included to the block.
34 Default value for block is 0:$, meaning the whole input stream.
36 -Both \fIstart\fR and \fIstop\fR strings are included to block. Nonprintable characters can be escaped as
37 +Both \fIstart\fR and \fIstop\fR strings are included in block. Nonprintable characters can be escaped as
43 Character '\e' can be escaped as '\e\e'. Escape codes '\ea','\eb','\et','\en','\ev','\ef','\er' and '\e;' can also be used.
45 -Length (\fIN\fR and \fIM\fR) can be defined as decimal (n), hexadecimal (xn) or octal (0n) value.
46 +Length (\fIN\fR and \fIM\fR) can be defined as a decimal (n), a hexadecimal (xn) or an octal (0n) value.
47 .SH "COMMAND SYNOPSIS"
48 -\fBbbe\fR has two type of commands: block and byte commands, both are allways related to current block. That means that the input stream outside of block remains untouched.
49 +\fBbbe\fR has two type of commands: block and byte commands, both are always related to current block. That means that the input stream outside of the blocks remains untouched.
54 Append the string \fIstring\fR at the end of block.
57 -Skip \fIn\fR blocks before executing commands after this command.
58 +Skip \fIn\fR blocks, before executing commands after this command.
61 Leave all blocks unmodified starting from block number \fIn\fR. Affects only commands after this command.
63 Before printing a block, the file name in which the block starts is printed.
66 -Before printing a block, the input stream offset at the begining of the block is printed.
67 +Before printing a block, the input stream offset at the beginning of the block is printed.
68 \fIf\fR can be H, D or O for Hexadecimal, Decimal or Octal format of offset.
72 \fIf\fR can be H, D or O for Hexadecimal, Decimal or Octal format of block number.
75 -Before printing a block, the contents of file \fIfile\fR is printed.
76 +Before printing a block, the contents of file \fIfile\fR are printed.
79 -After printing a block, the contents of file \fIfile\fR is printed.
80 +After printing a block, the contents of file \fIfile\fR are printed.
82 -\fIn\fR in byte commands is offset from the beginning of current block (starts from zero).
83 +\fIn\fR in byte commands is the offset from the beginning of current block (starts from zero).
85 r \fIn\fR \fIstring\fR
86 Replace bytes starting at position \fIn\fR with string \fIstring\fR.
90 The contents of block is printed in format defined by \fIformat\fR. \fIformat\fR
91 -can have any of the formats H, D, O, A and B for Hexadecimal, Decimal, Octal, Asciii and Binary.
92 +can have any of the formats H, D, O, A and B for Hexadecimal, Decimal, Octal, Ascii and Binary.
94 s/\fIsearch\fR/\fIreplace\fR/
95 Replace all occurrences of \fIsearch\fR with \fIreplace\fR.
97 y/\fIsource\fR/\fIdest\fR/
98 -Translate bytes in \fIsource\fR to the corresponding bytes in \fIdest\fR. \fISource\fR and \fIdest\fR must have equal length.
99 +Translate bytes in \fIsource\fR to the corresponding bytes in \fIdest\fR. \fISource\fR and \fIdest\fR must be the same length.
102 Delete \fIm\fR bytes starting from the offset \fIn\fR. If * is defined instead of \fIm\fR, then all bytes starting from \fIn\fR are deleted.
103 @@ -170,17 +170,17 @@
104 Commands after the l\-command are ignored from \fIn\fR'th byte of the block.
107 -Write bytes from the current block to file \fIfile\fR. Commands before w\-command have effect to what will be written. %B or %nB in \fIfile\fR will be replaced by current block number. n in %nB is field length,
108 +Write bytes from the current block to file \fIfile\fR. Commands before w\-command have what will be written. %B or %nB in \fIfile\fR will be replaced by current block number. n in %nB is field length,
109 leading zero in n causes the block number to be left padded with zeroes.
112 -Performs binary and with \fIc\fR.
113 +Performs binary \fBand\fR with \fIc\fR.
116 -Performs binary or with \fIc\fR.
117 +Performs binary \fBor\fR with \fIc\fR.
120 -Performs binary xor with \fIc\fR.
121 +Performs binary \fBxor\fR with \fIc\fR.
124 Performs binary negation.
128 bbe \-e "s/c:\e\etemp\e\edata1.txt/c:\e\etemp\e\edata2.txt/" file1
129 -all occurences of "c:\etemp\edata1.txt" in file file1 are changed to "c:\etemp\edata2.txt"
130 +all occurrences of "c:\etemp\edata1.txt" in file file1 are changed to "c:\etemp\edata2.txt"
132 bbe \-b 0420:16 \-e "r 4 \ex12\ex4a" file1
133 Two bytes starting at fifth byte of a 16 byte long block starting at offset 0420 (octal) in file1 are changed to hexadecimal values 12 and 4a.
138 -Timo Savinen <tjsa@iki.fi>
139 +Timo Savinen <tjsa@iki.fi >