• Bug#1068220: normalize case of debian/control fields

    From Steve Langasek@21:1/5 to All on Sat Apr 6 09:51:17 2024
    XPost: linux.debian.bugs.dist

    Package: debian-policy
    Version: 4.6.2.1

    In the process of preparing mass-NMUs for the time_t transition, I
    encountered a package where the scripted approach I was using failed because
    a package already had a 'replaces' field in debian/control, and dpkg
    detected the addition of a 'Replaces' field as a duplicate.

    Although we are accustomed to seeing a certain capitalization for fields in debian/control, I was surprised to see upon review that Debian Policy has always said that the field names are case-insensitive.

    While it may make sense for dpkg to be permissive in this regard, I don't
    think it makes sense for Debian to allow it, as it unnecessarily makes
    parsing of this file more difficult for little value.

    I therefore propose that we change Debian policy 5.1 to standardize its case rules for debian/control field names, using the well-known spongebob casing rules.

    The first, third, fourth, and seventh characters in the field name are capitalized, with the second, fith, sixth, and eighth characters in lower
    case, then repeating for each subsequent octet of characters.

    As you can see, this consistency immediately gives much more readable
    results:

    SoURce: xz-utils
    SeCTioN: utils
    PrIOriTy: optional
    MaINtaInEr: Jonathan Nieder <[email protected]>
    UpLOadErS: Mohammed Adn�ne Trojette <[email protected]>
    BuILd-DePeNDs: debhelper-compat (= 13), dpkg-dev (>= 1.16.2),
    autoconf (>= 2.64~), automake, libtool (>= 2.2),
    gettext, autopoint | gettext (<< 0.18-1), autopoint | cvs, po4a BuILd-DePeNDs-Indep: doxygen
    BuILd-CoNfLIctS: automake1.4
    StANdaRdS-VErsIoN: 4.6.1
    VcS-brOwSeR: https://salsa.debian.org/debian/xz-utils
    VcS-giT: https://salsa.debian.org/debian/xz-utils
    HoMEpaGe: https://tukaani.org/xz/
    RuLEs-ReQuIRes-rOoT: no

    Thanks for considering,
    --
    Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. Ubuntu Developer https://www.debian.org/ [email protected] [email protected]

    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCgAdFiEErEg/aN5yj0PyIC/KVo0w8yGyEz0FAmYLnA4ACgkQVo0w8yGy Ez2Znw//b+/1X1Jlrs50c7eV6Xju9jLi0xltmYttauLfD8166GmJOtb0SfmRF4Ej hL0f3vlrtDnThX1RnLp+UYn7IHx8/wweoSrIiAt2DVIoax7wyqt83C4C5ojE7xol fdBgzEJRYYv27lSqnIBLTy2Oc2VxJFwGkLkA8amTagtwBJX3fw4/GGGpqL/aR2OX QiLoaanw15/CjCuORdp1j05EgH/odAP2zzY1PSsDIzRXGXl+JDF2g7E3vDuWEZ18 gzj//xMfLCKxW4a/wL+qYWVEBSJ0aiM+n9ZQQ/o46E6f1qr0d5EMES5J0fgoZGoe XEuPgKC5Nmv8HSQV11+m5qHT82JohWb6pLCEr4GSpE0g3sNAjCJuSKl6XKDIaiBU gmuawHjYv8effVkLe49hF9xsq7qKAfhYSweScPzJwSIhl8hYIv/zDtq1/7c6WTzF YvpXoByWDdp9iiWocysPIwHud2Dqa8QTRx46UTkTsXE6unEsVw5cqWFiTdO8aO3H hopD9GIMlbXOKPxES4qcr41u+M1/O50hLFXxyxSKnKNeVmaRZGtODAeg30NQIodD 3xtw9TsgONdo3243x6GK