[Debian-med-packaging] Bug#1091922: routine-update: Consider using `debputy reformat`
Niels Thykier
niels at thykier.net
Thu Jan 2 14:56:42 GMT 2025
Package: routine-update
Severity: wishlist
X-Debbugs-Cc: niels at thykier.net
The `debputy reformat` tool can be run on all packages, apply their
maintainer's style or gracefully back out if none can be detected. The
full command your use case would be something like:
debputy reformat \
--auto-fix \
--unknown-or-unsupported-style-is-ok \
--no-linter-exit-code > /dev/null
In many cases, it would do nothing. But if the maintainer has selected a
style via `X-Style` or via the salsa-ci pipeline, then that command will
apply the style. You can use `--linter-exit-code` (instead of
`--no-linter-exit-code`) if you want to use the exit code to tell if
something was changed or not.
You can try the command on `debhelper` (has a style) vs. `phalanx` (does
not have a style) to see the difference.
Unlike `wrap-and-sort`, it does not rewrite the style by default. Though
if that behavior is desired, `debputy reformat --style black` is an
option (though I would recommend that routine-update then add the
`X-Style: black` field instead, so `debputy reformat` does the right
thing out of the box).
Dependencies: `apt-get install -y debputy-lsp`
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/debian-med-packaging/attachments/20250102/7817c231/attachment-0001.sig>
More information about the Debian-med-packaging
mailing list