-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Mark,
On 2/24/20 15:46, Mark Thomas wrote: > On 24/02/2020 20:31, Christopher Schultz wrote: >> Mark, > >> Why not use the full commit id instead of a prefix? Couldn't >> some future commit conflict with some arbitrary prefix? Or do I >> not know what the hell I'm talking about? > > No, you are spot on. The reason I used the prefix is that I was > transcribing the commit IDs by hand so the prefixes were easier. > We probably should use the full ID or at least a longer prefix. I wonder if we could script this: grab a prefix, find the (one and only one) commit in the repo and expand it. If there is a conflict (or more than one match), emit an error and continue without changing the commit id. When I do this kind of thing for $work, I like to write scripts that emit sed scripts. So you process e.g. security-8.html as input, but emit something like this as output: s/(\b)69c5608(\b)/\169c56080fb3355507e1b55d014ec0ee6767a6150\2/g ... You get a script that can be inspected, re-used and, even better, it doesn't directly modify the input files. So you can even do something like this: $ expand-git-commit-ids.pl security-*.xml > expand.sed $ sed -i .bak -f expand.sed security-*.xml And then if you find other files where the same kind of thing needs to be done, you can re-use the expand.sed script, or even (pun intended) expand the sed script if necessary. - -chris -----BEGIN PGP SIGNATURE----- Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/ iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAl5UPJMACgkQHPApP6U8 pFieGBAAmLLPqCvkLguhEr0aXmDfNmjYsiO6FssEHV2zjmqjM1zzDfgjI+WDwogs ctGkcCvITq1BYCVlGxMrkMyYkTI9a8i6lILMpAOIUwNvTVKDF3AGKaMB+EMNqyY9 8qiCrWaDbVLqpsSuGn5OhRqPui7yv8diik1cWnUKABqC/unkJqbRSEmkY9gVW8DJ P+rdC6PUK9osqNRttnJ7AKSuQJFBV4RGnQKDfVWFB7pnFAf9Dxy3W9xoy21NJAc5 GHB+AA/9PiNi1TUYClGI4LQnp/kMlGSeRGdtn0xRhVky/DqJehfHkZmUr8ec2Y1t eOBTLa7aP+Y19aaYiXZco3mXrbvsGGAJaeM+gX5CKpZHjFNAJV122FbP9smv+l/T Jdk10J2LJe3WtSR/ScKCPE4/ZXFG8pnEcNf3clT0nd8y2nuIdX6uOGPwyHMX5Cwr /IDFnuJDzy2/O5pfojFUGAfaVN+gzKRv7N2TaYXJt42FBKWfto1BFGvCxqmIIJCu xJDw+mLcGMfG6lximvc0mrmtOmd2CRjWfo6w12vp0/4pKyj39ZShgIT3lEg05hrC bLcYn+sHkoFgN8uiGjbDgpPZCsYn74HR/eoqZBgSfF0rBpOkNYfkfW4Yy8aUo8m3 ilpJrf/Oqn54ilkD4/v18rCIju+jd4XEiQdhjKao+Bj4zP6dGbg= =GeOn -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org