commit: eb346d01bba1e507085f4e338e1902a7f99d4305 Author: Michał Górny <mgorny <AT> gentoo <DOT> org> AuthorDate: Wed Feb 26 13:37:14 2020 +0000 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> CommitDate: Mon Mar 2 05:15:25 2020 +0000 URL: https://gitweb.gentoo.org/proj/policy-guide.git/commit/?id=eb346d01
Sort Policy Index keys by PGxx identifiers Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> Closes: https://github.com/gentoo/policy-guide/pull/15 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> exts/policyident.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/exts/policyident.py b/exts/policyident.py index 8cdc636..9679bba 100644 --- a/exts/policyident.py +++ b/exts/policyident.py @@ -41,7 +41,9 @@ class PolicyIndex(Index): '', # qualifier '')) # descr - return ([(k, sorted(v)) for k, v in entries.items()], False) + return (sorted([(k, sorted(v)) for k, v in entries.items()], + key=lambda kv: kv[1]), + False) def find_pg_id(section):
