File: pospell.1

package info (click to toggle)
spellutils 0.7-5
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, lenny, squeeze, wheezy
  • size: 1,052 kB
  • ctags: 360
  • sloc: ansic: 3,981; sh: 3,300; makefile: 242; sed: 93
file content (132 lines) | stat: -rw-r--r-- 2,746 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
.TH pospell 1 "APRIL 2000" Unix "User Manuals"

.SH NAME
pospell \- Run a program on the translation strings of a .po-file

.SH SYNOPSIS
.B pospell [-l
.I language
.B ] [-fsv]
.B -n
.I pofile
.B -p
.I program
.B [-- [
.I arguments...
.B ]]

.SH DESCRIPTION
.B pospell
copies the translations from the
.I pofile
to a temporary file (called the
.IR spellfile )
and then calls
.I program
with its
.IR arguments .
.I program
is supposed to somehow change the
.IR spellfile .
It is typically a spell checker. Afterwards the possibly changed
translations in
.I spellfile
is copied back into the
.IR pofile .

.PP
If
.I pofile
is specified as
.I \-
then
.B pospell
will act as a filter, i.e. standard input and standard output will
be used.

.PP
.B %f
in the
.I arguments
will be expanded to the name of the
.IR spellfile ,
or
.B \-
if the -f option is used. Use
.B %%
for a real % character.

All comment lines in the 
.I pofile
are replaced with lines with "#" as the only character in the
.IR spellfile .
The msgid strings with original text in the
.I pofile
are replaced with lines with ">" and "]" as the only characters in the
.IR spellfile .
The msgstr strings with file headers (i.e. strings without corresponding
msgid strings) are replaced with lines with ")" and "]" as the only
characters in the
.IR spellfile .
Don't change or remove these lines from the
.I spellfile
- they are used when the
.I spellfile
and the
.I pofile
are merged together after running the
.IR program .

The normal msgstr strings are copied to the
.I spellfile
with some changes:
1) The word msgstr and everything else before the string is replaced by a
"+" character.
2) Strings with C escape sequences followed by a letter like "one\\ttwo"
are split to parts like "one\\t" "two".
3) Leading whitespace in continuation lines is removed.
The changes of kind 1) and 2) are undone when the
.I spellfile
is copied back into the
.IR pofile ,
but removed whitespace will not be restored.

.SH OPTIONS
.IP -f
The called program is a filter so don't make a temporary file, but
pipe the
.I spellfile
to its standard input and read it back from its standard output.
.IP -l\ language
Only translations with the indicated language code are copied to the
.IR spellfile .
.IP -s
Quit with an error message if unrecognized items are found in the
.I pofile
or
.IR spellfile .

.IP -v
Print the version and exit.

.SH FILES
.B pospell
uses one or two temporary files with names given by the
.BR mkstemp (3)
or the
.BR tmpnam (3)
function.

.SH BUGS
If some system call gives an unexpected error
.B pospell
will stop immediately with an error message leaving its temporary
files.

.SH AUTHOR
Byrial Jensen <byrial@image.dk>

.SH SEE ALSO
The GNU gettext utilities.

.BR newsbody (1).