handle %license
[platform/upstream/rpmlint.git] / rpmlint.1
1 .TH RPMLINT "1" "April 2011" "rpmlint" "User Commands"
2 .SH NAME
3 rpmlint \- check common problems in rpm packages
4 .SH SYNOPSIS
5 \fBrpmlint\fR [\fIOPTION\fR]... [\fIFILE\fR|\fIPACKAGE\fR]...
6 .SH DESCRIPTION
7 \fBrpmlint\fR is a tool for checking common errors in rpm packages.
8 It can be used to test individual packages and spec files before
9 uploading or to check an entire distribution.  By default all
10 applicable checks are processed but specific checks can be performed
11 by using command line parameters.
12
13 \fIFILE\fR can be a rpm package file, a spec file, or a directory.  In
14 case of a directory, it is recursively searched for rpm and spec files
15 to check.  The special value \fB\-\fR results in standard input being
16 read and treated as (single) spec file content.
17 \fIPACKAGE\fR is the name of an installed package or a
18 .BR glob (7)
19 pattern to match installed packages, unless a file by that name exists.
20 .TP
21 \fB\-i\fR, \fB\-\-info\fR
22 Display explanations for reported messages.
23 .TP
24 \fB-I\fR, \fB\-\-explain\fR=\fImessageid\fR
25 Display explanations for the specified message identifiers and exit.
26 This option may be given multiple times.
27 .TP
28 \fB\-c\fR, \fB\-\-check\fR=\fIcheck\fR
29 Run only the specified check.  This option may be given multiple times
30 to specify multiple checks to run.  \fIcheck\fR is the name of the Python
31 module (as it would be given to Python's import statement) containing the
32 check.
33 .TP
34 \fB\-a\fR, \fB\-\-all\fR
35 Check all installed packages.
36 .TP
37 \fB\-C\fR, \fB\-\-checkdir\fR=\fIdir\fR
38 Insert \fIdir\fR to the front of the list of paths to load checks
39 from, unless it is already in the list.  The default list of check
40 dirs typically contains only /usr/share/rpmlint.  Directories in the
41 check dirs list are also inserted to the front of the list of paths to
42 load Python modules from when the check process begins.
43 .TP
44 \fB\-h\fR, \fB\-\-help\fR
45 Display summary of command line options and exit.
46 .TP
47 \fB\-v\fR, \fB\-\-verbose\fR
48 Operate in verbose mode.
49 .TP
50 \fB\-E\fR, \fB\-\-extractdir\fR=\fIdir\fR
51 Base directory for extracted temporary files, default is what Python's
52 tempfile.gettempdir() returns.
53 .TP
54 \fB\-V\fR, \fB\-\-version\fR
55 Display version information and exit.
56 .TP
57 \fB\-n\fR, \fB\-\-noexception\fR
58 Ignore output filters.
59 .TP
60 \fB\-\-rawout\fR=\fIfile\fR
61 Write unfiltered output to \fIfile\fR.
62 .TP
63 \fB\-f\fR, \fB\-\-file\fR=\fIconffile\fR
64 Load user configuration from the specified file, default is
65 $XDG_CONFIG_HOME/rpmlint (~/.config/rpmlint if $XDG_CONFIG_HOME is
66 empty or not set).
67 .TP
68 \fB\-o\fR, \fB\-\-option\fR=\fIvalue\fR
69 Override a configuration option.  \fIvalue\fR is a whitespace separated string,
70 first word of which is the option name to set, and the Python eval() return
71 value for the rest is set as the value for the option.  Passing only an option
72 name is treated as if None was passed as its value.  See the file "config"
73 shipped with rpmlint for the list of configuration options and their types.
74 For example:
75  \-o "NetworkEnabled True"
76  \-o "Distribution \(aqMy favorite distro\(aq"
77  \-o "MaxLineLength 80"
78  \-o "ValidShells (\(aq/bin/sh\(aq, \(aq/bin/bash\(aq)"
79 .SH CAVEATS
80 All checks do not apply to all argument types.  For best check
81 coverage, run rpmlint on all source and binary packages your build
82 produces.  The set of checks rpmlint runs on source packages is a
83 superset of the one for plain specfiles, the set of checks run for
84 installed binary packages is a superset of the one for uninstalled
85 binary package files, and the source and binary package check sets are
86 quite different.
87 .SH FILES
88 .TP
89 \fB/usr/share/rpmlint/config\fR, \fB/usr/share/rpmlint/config.*\fR
90 Built-in configuration.  When invoked as \fIsomeprefix\fR-rpmlint,
91 /usr/share/rpmlint/config.\fIsomeprefix\fR is used if it exists,
92 otherwise /usr/share/rpmlint/config.
93 .TP
94 \fB/etc/rpmlint/*config\fR
95 System wide configuration.
96 .TP
97 \fB$XDG_CONFIG_HOME/rpmlint\fR or \fB~/.config/rpmlint\fR
98 User configuration.
99 .SH EXIT CODES
100 .IP 0
101 No errors.
102 .IP 1
103 Unspecified error.
104 .IP 2
105 Interrupted.
106 .IP 64
107 One or more error message printed.
108 .IP 66
109 Badness threshold exceeded.
110 .SH AUTHOR
111 Originally written by Frédéric Lepied, see the file AUTHORS for (probably
112 incomplete) list of additional contributors.
113 .SH COPYRIGHT
114 This program is licensed under the GNU General Public License, see the
115 file COPYING included in the distribution archive.