Bug#849498: cme: Please allow "fixing" without restyling

Niels Thykier niels at thykier.net
Sat Aug 16 19:39:28 BST 2025


On Tue, 17 Jan 2017 14:09:00 +0100 Dominique Dumont <dod at debian.org> wrote:
> On Sunday, 1 January 2017 14:43:06 CET you wrote:
> > While I can get used to a field ordering
> > different from that used by dh-make, my main problem is the way cme
> > organizes lists-- it removes trailing commas and doesn't use a constant
> > indentation level globally.
> 
> Debian policy documents quite well what syntax is acceptable. Unfortunately, 
> there's no recommendation that help consistency between tools that generate 
> (or re-organize) control files (and other).
> 
> For instance, wrap-and-sort, dh-make* and cme all use different styles.
> 
> I would not mind changing cme output style if such a recommendation were 
> adopted
> 
> > Trying to maintain this isn't a one-time
> > fight with cme.
> 
> I understand your plight.
> 
> All the best
> 
> -- 
>  https://github.com/dod38fr/   -o- http://search.cpan.org/~ddumont/
> http://ddumont.wordpress.com/  -o-   irc: dod at irc.debian.org
> 
> 

Hi,

Chiming in on this rather old bug. Based on 
https://bugs.debian.org/895570#46, we know that `wrap-and-sort -ast` is 
the most popular styling. So in the absence of `cme` not being able to 
preserve the original input style, using `-ast` is likely to be a better 
default.

Secondly, I have introduced an `X-Style: black`[1] to `debian/control` 
to enable `debputy` to tell when people have opted into to automatic 
reformatting of `debian/*` files. The `black` style is maintained by 
`debputy reformat`, so ideally `cme` would use `debputy reformat` for 
formatting rather than using its own formatting. But, I appreciate that 
would be difficult to retrofit, and if `cme` would default to 
`wrap-and-sort -ast` parameters by default it would mostly align with 
`X-Style: black`. There are still some minor delta due to field ordering 
plus #1111291 and #1111292, but the big win would be `-ast` right now

Another alternative is to make `cme` not reformat at all and step out of 
this entire discussion. Though, I suspect if this was easy for `cme` to 
do then you would have already fixed this bug long ago.

Summing up, I hope I can convince you to migrate `cme` to use 
`wrap-and-sort -ast` style formatting in the interim in the absence of a 
full round-trip formatting-less safe parsing + write cycle.

Best regards,
Niels

[1]: More info at 
https://people.debian.org/~nthykier/blog/2024/debian-packaging-with-style-black.html 
if interesting.
-------------- 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/pkg-perl-maintainers/attachments/20250816/cf271e62/attachment.sig>


More information about the pkg-perl-maintainers mailing list