Debian Codegraph @

templates/man2/tee.2.pot

raw
1 # SOME DESCRIPTIVE TITLE
2 # Copyright (C) YEAR Free Software Foundation, Inc.
3 # This file is distributed under the same license as the PACKAGE package.
4 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5 #
6 #, fuzzy
7 msgid ""
8 msgstr ""
9 "Project-Id-Version: PACKAGE VERSION\n"
10 "POT-Creation-Date: 2026-06-05 06:48+0200\n"
11 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
12 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13 "Language-Team: LANGUAGE <[email protected]>\n"
14 "Language: \n"
15 "MIME-Version: 1.0\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
17 "Content-Transfer-Encoding: 8bit\n"
18
19 #. type: TH
20 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
21 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
22 #, no-wrap
23 msgid "tee"
24 msgstr ""
25
26 #. type: TH
27 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
28 #: opensuse-tumbleweed
29 #, no-wrap
30 msgid "2026-02-08"
31 msgstr ""
32
33 #. type: TH
34 #: archlinux debian-unstable
35 #, no-wrap
36 msgid "Linux man-pages 6.18"
37 msgstr ""
38
39 #. type: SH
40 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
41 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
42 #, no-wrap
43 msgid "NAME"
44 msgstr ""
45
46 #. type: Plain text
47 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
48 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
49 msgid "tee - duplicating pipe content"
50 msgstr ""
51
52 #. type: SH
53 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
54 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
55 #, no-wrap
56 msgid "LIBRARY"
57 msgstr ""
58
59 #. type: Plain text
60 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
61 #: opensuse-leap-16-1 opensuse-tumbleweed
62 msgid "Standard C library (I<libc>,\\ I<-lc>)"
63 msgstr ""
64
65 #. type: SH
66 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
67 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
68 #, no-wrap
69 msgid "SYNOPSIS"
70 msgstr ""
71
72 #. type: Plain text
73 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
74 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
75 #, no-wrap
76 msgid ""
77 "B<#define _GNU_SOURCE> /* See feature_test_macros(7) */\n"
78 "B<#include E<lt>fcntl.hE<gt>>\n"
79 msgstr ""
80
81 #. type: Plain text
82 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
83 #: opensuse-leap-16-1 opensuse-tumbleweed
84 #, no-wrap
85 msgid "B<ssize_t tee(int >I<fd_in>B<, int >I<fd_out>B<, size_t >I<size>B<, unsigned int >I<flags>B<);>\n"
86 msgstr ""
87
88 #. Return type was long before glibc 2.7
89 #. type: SH
90 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
91 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
92 #, no-wrap
93 msgid "DESCRIPTION"
94 msgstr ""
95
96 #
97 #
98 #. Example programs http://brick.kernel.dk/snaps
99 #. add a "tee(in, out1, out2)" system call that duplicates the pages
100 #. (again, incrementing their reference count, not copying the data) from
101 #. one pipe to two other pipes.
102 #. type: Plain text
103 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
104 #: opensuse-leap-16-1 opensuse-tumbleweed
105 msgid ""
106 "B<tee>() duplicates up to I<size> bytes of data from the pipe referred to "
107 "by the file descriptor I<fd_in> to the pipe referred to by the file "
108 "descriptor I<fd_out>. It does not consume the data that is duplicated from "
109 "I<fd_in>; therefore, that data can be copied by a subsequent B<splice>(2)."
110 msgstr ""
111
112 #. type: Plain text
113 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
114 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
115 msgid ""
116 "I<flags> is a bit mask that is composed by ORing together zero or more of "
117 "the following values:"
118 msgstr ""
119
120 #. type: TP
121 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
122 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
123 #, no-wrap
124 msgid "B<SPLICE_F_MOVE>"
125 msgstr ""
126
127 #. type: Plain text
128 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
129 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
130 msgid "Currently has no effect for B<tee>(); see B<splice>(2)."
131 msgstr ""
132
133 #. type: TP
134 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
135 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
136 #, no-wrap
137 msgid "B<SPLICE_F_NONBLOCK>"
138 msgstr ""
139
140 #. type: Plain text
141 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
142 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
143 msgid "Do not block on I/O; see B<splice>(2) for further details."
144 msgstr ""
145
146 #. type: TP
147 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
148 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
149 #, no-wrap
150 msgid "B<SPLICE_F_MORE>"
151 msgstr ""
152
153 #. type: Plain text
154 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
155 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
156 msgid ""
157 "Currently has no effect for B<tee>(), but may be implemented in the future; "
158 "see B<splice>(2)."
159 msgstr ""
160
161 #. type: TP
162 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
163 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
164 #, no-wrap
165 msgid "B<SPLICE_F_GIFT>"
166 msgstr ""
167
168 #. type: Plain text
169 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
170 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
171 msgid "Unused for B<tee>(); see B<vmsplice>(2)."
172 msgstr ""
173
174 #. type: SH
175 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
176 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
177 #, no-wrap
178 msgid "RETURN VALUE"
179 msgstr ""
180
181 #. type: Plain text
182 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
183 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
184 msgid ""
185 "Upon successful completion, B<tee>() returns the number of bytes that were "
186 "duplicated between the input and output. A return value of 0 means that "
187 "there was no data to transfer, and it would not make sense to block, because "
188 "there are no writers connected to the write end of the pipe referred to by "
189 "I<fd_in>."
190 msgstr ""
191
192 #. type: Plain text
193 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
194 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
195 msgid ""
196 "On error, B<tee>() returns -1 and I<errno> is set to indicate the error."
197 msgstr ""
198
199 #. type: SH
200 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
201 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
202 #, no-wrap
203 msgid "ERRORS"
204 msgstr ""
205
206 #. type: TP
207 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
208 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
209 #, no-wrap
210 msgid "B<EAGAIN>"
211 msgstr ""
212
213 #. type: Plain text
214 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
215 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
216 msgid ""
217 "B<SPLICE_F_NONBLOCK> was specified in I<flags> or one of the file "
218 "descriptors had been marked as nonblocking (B<O_NONBLOCK>)B<,> and the "
219 "operation would block."
220 msgstr ""
221
222 #. type: TP
223 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
224 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
225 #, no-wrap
226 msgid "B<EINVAL>"
227 msgstr ""
228
229 #. type: Plain text
230 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
231 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
232 msgid ""
233 "I<fd_in> or I<fd_out> does not refer to a pipe; or I<fd_in> and I<fd_out> "
234 "refer to the same pipe."
235 msgstr ""
236
237 #. type: TP
238 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
239 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
240 #, no-wrap
241 msgid "B<ENOMEM>"
242 msgstr ""
243
244 #. type: Plain text
245 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
246 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
247 msgid "Out of memory."
248 msgstr ""
249
250 #. type: SH
251 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
252 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
253 #, no-wrap
254 msgid "STANDARDS"
255 msgstr ""
256
257 #. type: Plain text
258 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
259 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
260 msgid "Linux."
261 msgstr ""
262
263 #. type: SH
264 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
265 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
266 #, no-wrap
267 msgid "HISTORY"
268 msgstr ""
269
270 #. type: Plain text
271 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
272 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
273 msgid "Linux 2.6.17, glibc 2.5."
274 msgstr ""
275
276 #. type: SH
277 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
278 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
279 #, no-wrap
280 msgid "NOTES"
281 msgstr ""
282
283 #. type: Plain text
284 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
285 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
286 msgid ""
287 "Conceptually, B<tee>() copies the data between the two pipes. In reality "
288 "no real data copying takes place though: under the covers, B<tee>() assigns "
289 "data to the output by merely grabbing a reference to the input."
290 msgstr ""
291
292 #. type: SH
293 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
294 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
295 #, no-wrap
296 msgid "EXAMPLES"
297 msgstr ""
298
299 #. type: Plain text
300 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
301 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
302 msgid ""
303 "The example below implements a basic B<tee>(1) program using the B<tee>() "
304 "system call. Here is an example of its use:"
305 msgstr ""
306
307 #. type: Plain text
308 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
309 #: opensuse-tumbleweed
310 #, no-wrap
311 msgid ""
312 "$B< date | ./a.out out.log | cat>;\n"
313 "Tue Oct 28 10:06:00 CET 2014\n"
314 "$B< cat out.log>;\n"
315 "Tue Oct 28 10:06:00 CET 2014\n"
316 msgstr ""
317
318 #. type: SS
319 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
320 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
321 #, no-wrap
322 msgid "Program source"
323 msgstr ""
324
325 #. type: Plain text
326 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
327 #: opensuse-leap-16-1 opensuse-tumbleweed
328 #, no-wrap
329 msgid ""
330 "#define _GNU_SOURCE\n"
331 "#include E<lt>errno.hE<gt>\n"
332 "#include E<lt>fcntl.hE<gt>\n"
333 "#include E<lt>limits.hE<gt>\n"
334 "#include E<lt>stdio.hE<gt>\n"
335 "#include E<lt>stdlib.hE<gt>\n"
336 "#include E<lt>sys/types.hE<gt>\n"
337 "#include E<lt>unistd.hE<gt>\n"
338 "\\&\n"
339 "int\n"
340 "main(int argc, char *argv[])\n"
341 "{\n"
342 " int fd;\n"
343 " ssize_t size, ssize;\n"
344 "\\&\n"
345 " if (argc != 2) {\n"
346 " fprintf(stderr, \"Usage: %s E<lt>fileE<gt>\\[rs]n\", argv[0]);\n"
347 " exit(EXIT_FAILURE);\n"
348 " }\n"
349 "\\&\n"
350 " fd = open(argv[1], O_WRONLY | O_CREAT | O_TRUNC, 0644);\n"
351 " if (fd == -1) {\n"
352 " perror(\"open\");\n"
353 " exit(EXIT_FAILURE);\n"
354 " }\n"
355 "\\&\n"
356 " for (;;) {\n"
357 " /*\n"
358 " * tee stdin to stdout.\n"
359 " */\n"
360 " size = tee(STDIN_FILENO, STDOUT_FILENO,\n"
361 " INT_MAX, SPLICE_F_NONBLOCK);\n"
362 " if (size E<lt> 0) {\n"
363 " if (errno == EAGAIN)\n"
364 " continue;\n"
365 " perror(\"tee\");\n"
366 " exit(EXIT_FAILURE);\n"
367 " }\n"
368 " if (size == 0)\n"
369 " break;\n"
370 "\\&\n"
371 " /*\n"
372 " * Consume stdin by splicing it to a file.\n"
373 " */\n"
374 " while (size E<gt> 0) {\n"
375 " ssize = splice(STDIN_FILENO, NULL, fd, NULL,\n"
376 " size, SPLICE_F_MOVE);\n"
377 " if (ssize E<lt> 0) {\n"
378 " perror(\"splice\");\n"
379 " exit(EXIT_FAILURE);\n"
380 " }\n"
381 " size -= ssize;\n"
382 " }\n"
383 " }\n"
384 "\\&\n"
385 " close(fd);\n"
386 " exit(EXIT_SUCCESS);\n"
387 "}\n"
388 msgstr ""
389
390 #. SRC END
391 #. type: SH
392 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
393 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
394 #, no-wrap
395 msgid "SEE ALSO"
396 msgstr ""
397
398 #. type: Plain text
399 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
400 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
401 msgid "B<splice>(2), B<vmsplice>(2), B<pipe>(7)"
402 msgstr ""
403
404 #. type: TH
405 #: debian-trixie
406 #, no-wrap
407 msgid "2024-06-15"
408 msgstr ""
409
410 #. type: TH
411 #: debian-trixie
412 #, no-wrap
413 msgid "Linux man-pages 6.9.1"
414 msgstr ""
415
416 #. type: Plain text
417 #: debian-trixie
418 msgid "Standard C library (I<libc>, I<-lc>)"
419 msgstr ""
420
421 #. type: Plain text
422 #: debian-trixie
423 #, no-wrap
424 msgid "B<ssize_t tee(int >I<fd_in>B<, int >I<fd_out>B<, size_t >I<len>B<, unsigned int >I<flags>B<);>\n"
425 msgstr ""
426
427 #
428 #
429 #. Example programs http://brick.kernel.dk/snaps
430 #. add a "tee(in, out1, out2)" system call that duplicates the pages
431 #. (again, incrementing their reference count, not copying the data) from
432 #. one pipe to two other pipes.
433 #. type: Plain text
434 #: debian-trixie
435 msgid ""
436 "B<tee>() duplicates up to I<len> bytes of data from the pipe referred to by "
437 "the file descriptor I<fd_in> to the pipe referred to by the file descriptor "
438 "I<fd_out>. It does not consume the data that is duplicated from I<fd_in>; "
439 "therefore, that data can be copied by a subsequent B<splice>(2)."
440 msgstr ""
441
442 #. type: Plain text
443 #: debian-trixie fedora-44 fedora-rawhide
444 #, no-wrap
445 msgid ""
446 "$ B<date | ./a.out out.log | cat>\n"
447 "Tue Oct 28 10:06:00 CET 2014\n"
448 "$ B<cat out.log>\n"
449 "Tue Oct 28 10:06:00 CET 2014\n"
450 msgstr ""
451
452 #. type: Plain text
453 #: debian-trixie
454 #, no-wrap
455 msgid ""
456 "#define _GNU_SOURCE\n"
457 "#include E<lt>errno.hE<gt>\n"
458 "#include E<lt>fcntl.hE<gt>\n"
459 "#include E<lt>limits.hE<gt>\n"
460 "#include E<lt>stdio.hE<gt>\n"
461 "#include E<lt>stdlib.hE<gt>\n"
462 "#include E<lt>sys/types.hE<gt>\n"
463 "#include E<lt>unistd.hE<gt>\n"
464 "\\&\n"
465 "int\n"
466 "main(int argc, char *argv[])\n"
467 "{\n"
468 " int fd;\n"
469 " ssize_t len, slen;\n"
470 "\\&\n"
471 " if (argc != 2) {\n"
472 " fprintf(stderr, \"Usage: %s E<lt>fileE<gt>\\[rs]n\", argv[0]);\n"
473 " exit(EXIT_FAILURE);\n"
474 " }\n"
475 "\\&\n"
476 " fd = open(argv[1], O_WRONLY | O_CREAT | O_TRUNC, 0644);\n"
477 " if (fd == -1) {\n"
478 " perror(\"open\");\n"
479 " exit(EXIT_FAILURE);\n"
480 " }\n"
481 "\\&\n"
482 " for (;;) {\n"
483 " /*\n"
484 " * tee stdin to stdout.\n"
485 " */\n"
486 " len = tee(STDIN_FILENO, STDOUT_FILENO,\n"
487 " INT_MAX, SPLICE_F_NONBLOCK);\n"
488 " if (len E<lt> 0) {\n"
489 " if (errno == EAGAIN)\n"
490 " continue;\n"
491 " perror(\"tee\");\n"
492 " exit(EXIT_FAILURE);\n"
493 " }\n"
494 " if (len == 0)\n"
495 " break;\n"
496 "\\&\n"
497 " /*\n"
498 " * Consume stdin by splicing it to a file.\n"
499 " */\n"
500 " while (len E<gt> 0) {\n"
501 " slen = splice(STDIN_FILENO, NULL, fd, NULL,\n"
502 " len, SPLICE_F_MOVE);\n"
503 " if (slen E<lt> 0) {\n"
504 " perror(\"splice\");\n"
505 " exit(EXIT_FAILURE);\n"
506 " }\n"
507 " len -= slen;\n"
508 " }\n"
509 " }\n"
510 "\\&\n"
511 " close(fd);\n"
512 " exit(EXIT_SUCCESS);\n"
513 "}\n"
514 msgstr ""
515
516 #. type: TH
517 #: fedora-44 fedora-rawhide
518 #, no-wrap
519 msgid "2024-11-17"
520 msgstr ""
521
522 #. type: TH
523 #: fedora-44 fedora-rawhide
524 #, no-wrap
525 msgid "Linux man-pages 6.13"
526 msgstr ""
527
528 #. type: TH
529 #: mageia-cauldron
530 #, no-wrap
531 msgid "Linux man-pages 6.17"
532 msgstr ""
533
534 #. type: TH
535 #: opensuse-leap-16-1 opensuse-tumbleweed
536 #, no-wrap
537 msgid "Linux man-pages (unreleased)"
538 msgstr ""