Debian Codegraph @

upstream/mageia-cauldron/man1/encguess.1

raw
1 .\" -*- mode: troff; coding: utf-8 -*-
2 .\" Automatically generated by Pod::Man v6.0.2 (Pod::Simple 3.45)
3 .\"
4 .\" Standard preamble:
5 .\" ========================================================================
6 .de Sp \" Vertical space (when we can't use .PP)
7 .if t .sp .5v
8 .if n .sp
9 ..
10 .de Vb \" Begin verbatim text
11 .ft CW
12 .nf
13 .ne \\$1
14 ..
15 .de Ve \" End verbatim text
16 .ft R
17 .fi
18 ..
19 .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
20 .ie n \{\
21 . ds C` ""
22 . ds C' ""
23 'br\}
24 .el\{\
25 . ds C`
26 . ds C'
27 'br\}
28 .\"
29 .\" Escape single quotes in literal strings from groff's Unicode transform.
30 .ie \n(.g .ds Aq \(aq
31 .el .ds Aq '
32 .\"
33 .\" If the F register is >0, we'll generate index entries on stderr for
34 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
35 .\" entries marked with X<> in POD. Of course, you'll have to process the
36 .\" output yourself in some meaningful fashion.
37 .\"
38 .\" Avoid warning from groff about undefined register 'F'.
39 .de IX
40 ..
41 .nr rF 0
42 .if \n(.g .if rF .nr rF 1
43 .if (\n(rF:(\n(.g==0)) \{\
44 . if \nF \{\
45 . de IX
46 . tm Index:\\$1\t\\n%\t"\\$2"
47 ..
48 . if !\nF==2 \{\
49 . nr % 0
50 . nr F 2
51 . \}
52 . \}
53 .\}
54 .rr rF
55 .\"
56 .\" Required to disable full justification in groff 1.23.0.
57 .if n .ds AD l
58 .\" ========================================================================
59 .\"
60 .IX Title "ENCGUESS 1"
61 .TH ENCGUESS 1 2026-05-26 "perl v5.42.0" "Perl Programmers Reference Guide"
62 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
63 .\" way too many mistakes in technical documents.
64 .if n .ad l
65 .nh
66 .SH NAME
67 encguess \- guess character encodings of files
68 .SH VERSION
69 .IX Header "VERSION"
70 \&\f(CW$Id:\fR encguess,v 0.4 2023/11/10 01:10:50 dankogai Exp $
71 .SH SYNOPSIS
72 .IX Header "SYNOPSIS"
73 .Vb 1
74 \& encguess [switches] filename...
75 .Ve
76 .SS SWITCHES
77 .IX Subsection "SWITCHES"
78 .IP \-h 2
79 .IX Item "-h"
80 show this message and exit.
81 .IP \-s 2
82 .IX Item "-s"
83 specify a list of "suspect encoding types" to test,
84 separated by either \f(CW\*(C`:\*(C'\fR or \f(CW\*(C`,\*(C'\fR
85 .IP \-S 2
86 .IX Item "-S"
87 output a list of all acceptable encoding types that can be used with
88 the \-s param
89 .IP \-u 2
90 .IX Item "-u"
91 suppress display of unidentified types
92 .SS EXAMPLES:
93 .IX Subsection "EXAMPLES:"
94 .IP \(bu 2
95 Guess encoding of a file named \f(CW\*(C`test.txt\*(C'\fR, using only the default
96 suspect types.
97 .Sp
98 .Vb 1
99 \& encguess test.txt
100 .Ve
101 .IP \(bu 2
102 Guess the encoding type of a file named \f(CW\*(C`test.txt\*(C'\fR, using the suspect
103 types \f(CW\*(C`euc\-jp,shiftjis,7bit\-jis\*(C'\fR.
104 .Sp
105 .Vb 2
106 \& encguess \-s euc\-jp,shiftjis,7bit\-jis test.txt
107 \& encguess \-s euc\-jp:shiftjis:7bit\-jis test.txt
108 .Ve
109 .IP \(bu 2
110 Guess the encoding type of several files, do not display results for
111 unidentified files.
112 .Sp
113 .Vb 1
114 \& encguess \-us euc\-jp,shiftjis,7bit\-jis test*.txt
115 .Ve
116 .SH DESCRIPTION
117 .IX Header "DESCRIPTION"
118 The encoding identification is done by checking one encoding type at a
119 time until all but the right type are eliminated. The set of encoding
120 types to try is defined by the \-s parameter and defaults to ascii,
121 utf8 and UTF\-16/32 with BOM. This can be overridden by passing one or
122 more encoding types via the \-s parameter. If you need to pass in
123 multiple suspect encoding types, use a quoted string with the a space
124 separating each value.
125 .SH "SEE ALSO"
126 .IX Header "SEE ALSO"
127 Encode::Guess, Encode::Detect
128 .SH "LICENSE AND COPYRIGHT"
129 .IX Header "LICENSE AND COPYRIGHT"
130 Copyright 2015 Michael LaGrasta and Dan Kogai.
131 .PP
132 This program is free software; you can redistribute it and/or modify it
133 under the terms of the Artistic License (2.0). You may obtain a
134 copy of the full license at:
135 .PP
136 <http://www.perlfoundation.org/artistic_license_2_0>