man > wrap-and-sort(1)

WRAP-AND-SORT(1)                       General Commands Manual                      WRAP-AND-SORT(1)

NAME
       wrap-and-sort - wrap long lines and sort items in Debian packaging files

SYNOPSIS
       wrap-and-sort [options]


DESCRIPTION
       wrap-and-sort wraps the package lists in Debian control files. By default the lists will only
       split  into multiple lines if the entries are longer than the maximum line length limit of 79
       characters. wrap-and-sort sorts the package lists in Debian  control  files  and  all  .dirs,
       .docs,  .examples,  .info,  .install,  .links, .maintscript, and .manpages files. Beside that
       wrap-and-sort removes trailing spaces in these files.

       This script should be run in the root of a Debian package tree. It searches for control, con‐
       trol*.in, copyright, copyright.in, install, and *.install in the debian directory.


OPTIONS
       -h, --help
              Show this help message and exit.

       -a, --wrap-always
              Wrap all package lists in the Debian control file even if they do not exceed the  line
              length limit and could fit in one line.

       -s, --short-indent
              Only indent wrapped lines by one space (default is in-line with the field name).

       -b, --sort-binary-packages
              Sort binary package paragraphs by name.

       -k, --keep-first
              When sorting binary package paragraphs, leave the first one at the top.

              Unqualified debhelper(7) configuration files are applied to the first package.

       --no-keep-first
              When  sorting binary package paragraphs, do not treat the first package specially (op‐
              posite of --keep-first)

       -n, --no-cleanup
              Do not remove trailing whitespaces.

       -t, --trailing-comma
              Add a trailing comma at the end of the sorted fields.  This minimizes  future  differ‐
              ences in the VCS commits when additional dependencies are appended or removed.

       -d path, --debian-directory=path
              Location of the debian directory (default: ./debian).

       -f file, --file=file
              Wrap and sort only the specified file.  You can specify this parameter multiple times.
              All supported files will be processed if no files are specified.

       -v, --verbose
              Print all files that are touched.

       --max-line-length=max_line_length
              Set the maximum allowed line length. Package lists in the Debian control file that ex‐
              ceed this length limit will be wrapped.

              The default maximum line length is 79 characters.

       -N, --dry-run
              Do not modify any file, instead only print the files that would be modified.


       --experimental-rts-parser
              Temporary option accepted for compatibility with an experiment. It no longer does any‐
              thing. Please remove any use of it.


AUTHORS
       wrap-and-sort and this manpage have been written by Benjamin Drung <bdrung AT debian.org>.

       Both are released under the ISC license.

DEBIAN                                    Debian Utilities                          WRAP-AND-SORT(1)
wrap-and-sort(1)
NAME SYNOPSIS DESCRIPTION OPTIONS
-h, --help -a, --wrap-always -s, --short-indent -b, --sort-binary-packages -k, --keep-first --no-keep-first -n, --no-cleanup -t, --trailing-comma -d path, --debian-directory=path -f file, --file=file -v, --verbose -N, --dry-run --experimental-rts-parser
AUTHORS

Generated by phpman v4.9.26-5-g7740029 · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-08-30 17:53 @216.73.217.135
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 Transitional!Valid CSS!

^_top_^