Kapitel 7. Quality of packaging

# Kapitel 7. Quality of packaging

The quality of Debian packaging can be improved by using testing tools.

- lintian(1)
- piuparts(1)
- autopkgtest(1)

If you follow „Kapitel 4, Werkzeugeinrichtung“, these are automatically executed. You are expected to fix all warnings.

## 7.1. Reformat debian/* files with wrap-and-sort

It is a good idea to reformat debian/* files consistently using the wrap-and-sort(1) command in devscripts package.

Reformat debian/* files.

    [debhello-0.0] $ wrap-and-sort -vast

## 7.2. Validate debian/* files with debputy

The new debputy tool [17] includes subcommands to validate (and fix) most files in debian/*.

Check correctness of files in debian/*.

    [debhello-0.0] $ debputy lint --spellcheck

Format debian/control and debian/tests/control files.

    [debhello-0.0] $ debputy reformat --style black

Using the „debputy reformat“ command obsoletes using „wrap-and-sort -vast“.

The debputy tool also includes a language server. You can set up to get real-time feedback while editing debian/* files with any modern editor supporting the Language Server Protocol.

## 7.3. Check packaging with cme

It is a good idea to check dpkg configuration files using the cme(1) command in cme package. This is used by the DFSG, Licensing & New Packages Team.

Check correctness using in cme.

    [debhello-0.0] $ cme fix --verbose dpkg

[17] The main purpose of the debputy tool is to offer a new Debian package build paradigm. This new paradigm is beyond the scope of this tutorial.

Kapitel 6. Basics for packaging |  | Kapitel 8. Sanitization of the source