1DEBDIFF(1)                  General Commands Manual                 DEBDIFF(1)
2
3
4

NAME

6       debdiff - compare file lists in two Debian packages
7

SYNOPSIS

9       debdiff [options]
10       debdiff [options] ... deb1 deb2
11       debdiff [options] ... changes1 changes2
12       debdiff [options] ... --from deb1a deb1b ...  --to deb2a deb2b ...
13       debdiff [options] ... dsc1 dsc2
14

DESCRIPTION

16       debdiff  takes  the names of two Debian package files (.debs or .udebs)
17       on the command line and compares their contents (considering  only  the
18       files  in  the  main  package,  not the maintenance scripts).  It shows
19       which files have been introduced and  which  removed  between  the  two
20       package  files,  and  is  therefore useful for spotting files which may
21       have been inadvertently lost between revisions of the package.  It also
22       checks  the file owners and permissions, and compares the control files
23       of the two packages using the wdiff program.  If you want a deeper com‐
24       parison of two Debian package files you can use the diffoscope tool.
25
26       If  no arguments are given, debdiff tries to compare the content of the
27       current source directory with the last version of the package.
28
29       debdiff can also handle changes between groups of  .deb  files  in  two
30       ways.   The  first is to specify two .changes files.  In this case, the
31       .deb files listed in the .changes file will be compared, by taking  the
32       contents  of  all  of  the listed .deb files together.  (The .deb files
33       listed are assumed to be in the same directory as the  .changes  file.)
34       The second way is to list the .deb files of interest specifically using
35       the --from ... --to syntax.  These both help if a package is broken  up
36       into  smaller packages and one wishes to ensure that nothing is lost in
37       the interim.
38
39       debdiff examines the devscripts configuration files as described below.
40       Command line options override the configuration file settings, though.
41
42       If  debdiff  is passed two source packages (.dsc files) it will compare
43       the contents of the source packages.  If  the  source  packages  differ
44       only in Debian revision number (that is, the .orig.tar.gz files are the
45       same in the two .dsc files), then interdiff(1) will be used to  compare
46       the  two patch files if this program is available on the system, other‐
47       wise a diff will be performed between the two source trees.
48

OPTIONS

50       --dirs, -d
51              The default mode of operation is to ignore directory names which
52              appear  in  the  file list, but they, too, will be considered if
53              this option is given.
54
55       --nodirs
56              Ignore directory names which appear in the file list.   This  is
57              the  default and it can be used to override a configuration file
58              setting.
59
60       --move FROM TO, -m FROM TO
61              It sometimes occurs that various files or directories are  moved
62              around  between  revisions.   This can be handled using this op‐
63              tion.  There are two arguments, the first giving the location of
64              the  directory  or  file in the first package, and the second in
65              the second.  Any files in the first listing  whose  names  begin
66              with  the  first argument are treated as having that substituted
67              for the second argument when the file lists are  compared.   Any
68              number  of  --move arguments may be given; they are processed in
69              the order in which they appear. This only affects comparing  bi‐
70              nary packages, not source packages.
71
72       --move-regex FROM TO
73              This  is  the  same  as --move, except that FROM is treated as a
74              regular expression and the perl substitution command s/^FROM/TO/
75              is  applied  to  the  files.   In particular, TO can make use of
76              backreferences such as $1.
77
78       --nocontrol
79              debdiff will usually compare the respective control files of the
80              packages  using  wdiff(1).   This option suppresses this part of
81              the processing.
82
83       --control
84              Compare the respective control files; this is the  default,  and
85              it can be used to override a configuration file setting.
86
87       --controlfiles FILE[,FILE ...]
88              Specify  which control files to compare; by default this is just
89              control, but could include postinst, config and  so  on.   Files
90              will  only  be  compared if they are present in both .debs being
91              compared.  The special value  ALL  compares  all  control  files
92              present  in  both packages, except for md5sums.  This option can
93              be used to override a configuration file setting.
94
95       --wdiff-source-control
96              When processing source packages, compare control files using wd‐
97              iff.  Equivalent to the --control option for binary packages.
98
99       --no-wdiff-source-control
100              Do  not  compare  control  files in source packages using wdiff.
101              This is the default.
102
103       --wp, --wl, --wt
104              Pass a -p, -l or -t option to wdiff respectively.  (This  yields
105              the  whole  wdiff  output  rather  than  just the lines with any
106              changes.)
107
108       --show-moved
109              If multiple .deb files are specified on the command line, either
110              using .changes files or the --from/--to syntax, then this option
111              will also show which files (if any) have moved between packages.
112              (The  package  names are simply determined from the names of the
113              .deb files.)
114
115       --noshow-moved
116              The default behaviour; can be used to override  a  configuration
117              file setting.
118
119       --renamed FROM TO
120              If  --show-moved is being used and a package has been renamed in
121              the process, this command instructs debdiff to treat the package
122              in the first list called FROM as if it were called TO.  Multiple
123              uses of this option are permitted.
124
125       --exclude PATTERN
126              Exclude files whose basenames match PATTERN.  Multiple  uses  of
127              this  option  are permitted.  Note that this option is passed on
128              to diff and has the same behaviour, so only the basename of  the
129              file  is  considered:  in  particular,  --exclude='*.patch' will
130              work, but --exclude='debian/patches/*' will  have  no  practical
131              effect.
132
133       --diffstat
134              Include the result of diffstat before the generated diff.
135
136       --no-diffstat
137              The  default  behaviour; can be used to override a configuration
138              file setting.
139
140       --auto-ver-sort
141              When comparing source packages, do so in version order.
142
143       --no-auto-ver-sort
144              Compare source packages in the order they  were  passed  on  the
145              command-line,  even  if  that  means  comparing a package with a
146              higher version against one with a lower version.   This  is  the
147              default behaviour.
148
149       --unpack-tarballs
150              When  comparing  source  packages, also unpack tarballs found in
151              the top level source directory to compare their  contents  along
152              with the other files.  This is the default behaviour.
153
154       --no-unpack-tarballs
155              Do not unpack tarballs inside source packages.
156
157       --no-conf, --noconf
158              Do  not  read any configuration files.  This can only be used as
159              the first option given on the command-line.
160
161       --debs-dir directory
162              Look for the .dsc files in directory instead of  the  parent  of
163              the source directory.  This should either be an absolute path or
164              relative to the top of the source directory.
165
166       --help, -h
167              Show a summary of options.
168
169       --version, -v
170              Show version and copyright information.
171
172       --quiet, -q
173              Be quiet if no differences were found.
174
175       --ignore-space, -w
176              Ignore whitespace in diffs.
177

CONFIGURATION VARIABLES

179       The two configuration files /etc/devscripts.conf and ~/.devscripts  are
180       sourced  by a shell in that order to set configuration variables.  Com‐
181       mand line options can be used to override configuration file  settings.
182       Environment  variable  settings are ignored for this purpose.  The cur‐
183       rently recognised variables are:
184
185       DEBDIFF_DIRS
186              If this is set to yes, then it is the same as the --dirs command
187              line parameter being used.
188
189       DEBDIFF_CONTROL
190              If  this  is  set  to no, then it is the same as the --nocontrol
191              command line parameter being used.  The default is yes.
192
193       DEBDIFF_CONTROLFILES
194              Which control files to  compare,  corresponding  to  the  --con‐
195              trolfiles command line option.  The default is control.
196
197       DEBDIFF_SHOW_MOVED
198              If  this  is set to yes, then it is the same as the --show-moved
199              command line parameter being used.
200
201       DEBDIFF_WDIFF_OPT
202              This option will be passed to wdiff; it should be one of -p,  -l
203              or -t.
204
205       DEBDIFF_SHOW_DIFFSTAT
206              If  this  is  set  to yes, then it is the same as the --diffstat
207              command line parameter being used.
208
209       DEBDIFF_WDIFF_SOURCE_CONTROL
210              If this is set to  yes,  then  it  is  the  same  as  the  --wd‐
211              iff-source-control command line parameter being used.
212
213       DEBDIFF_AUTO_VER_SORT
214              If   this   is   set  to  yes,  then  it  is  the  same  as  the
215              --auto-ver-sort command line parameter being used.
216
217       DEBDIFF_UNPACK_TARBALLS
218              If this is set to no, then  it  is  the  same  as  the  --no-un‐
219              pack-tarballs command line parameter being used.
220
221       DEBRELEASE_DEBS_DIR
222              This  specifies  the directory in which to look for the .dsc and
223              files, and is either an absolute path or relative to the top  of
224              the  source  tree.   This  corresponds to the --debs-dir command
225              line option.  This directive could be used, for example, if  you
226              always  use pbuilder or svn-buildpackage to build your packages.
227              Note that it also affects debrelease(1) in the same  way,  hence
228              the strange name of the option.
229

EXIT VALUES

231       Normally  the exit value will be 0 if no differences are reported and 1
232       if any are reported.  If there is some fatal error, the exit code  will
233       be 255.
234

SEE ALSO

236       debdiff-apply(1), diffstat(1), dpkg-deb(1), interdiff(1), wdiff(1), de‐
237       vscripts.conf(5), diffoscope(1)
238

AUTHOR

240       debdiff was originally written as a shell script by Yann  Dirson  <dir‐
241       son@debian.org> and rewritten in Perl with many more features by Julian
242       Gilbey <jdg@debian.org>.  The software may be freely redistributed  un‐
243       der the terms and conditions of the GNU General Public License, version
244       2.
245
246
247
248DEBIAN                         Debian Utilities                     DEBDIFF(1)
Impressum