aboutsummaryrefslogtreecommitdiff
path: root/scripts/theme-studio/app_inventory.py
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-06-19 11:09:01 -0400
committerCraig Jennings <c@cjennings.net>2026-06-19 11:09:01 -0400
commit569a539bea5e14acd91c6ddd0fdae01ee4bc6912 (patch)
tree44aba075fa07c772522b4c71986fac391e079929 /scripts/theme-studio/app_inventory.py
parenteef46e258885d893f2243f08310a0400a04ad166 (diff)
downloaddotemacs-569a539bea5e14acd91c6ddd0fdae01ee4bc6912.tar.gz
dotemacs-569a539bea5e14acd91c6ddd0fdae01ee4bc6912.zip
refactor(theme-studio): single-source the bespoke-app list in face_data
The bespoke apps were listed twice: generate.py's _BESPOKE_APPS (key, label, preview, faces, prefix, seed) and app_inventory's BESPOKE_APPS set of keys, which had drifted (it carried both "org" and "org-mode"). The spec list now lives in face_data.py as BESPOKE_APP_SPECS, beside the FACES/SEED constants it references. generate.py builds APPS from it, and app_inventory derives its exclusion set from the same keys plus an explicit "org" alias of the "org-mode" app. Adding a bespoke app is now one row. APPS order and the generated page are unchanged.
Diffstat (limited to 'scripts/theme-studio/app_inventory.py')
-rw-r--r--scripts/theme-studio/app_inventory.py33
1 files changed, 7 insertions, 26 deletions
diff --git a/scripts/theme-studio/app_inventory.py b/scripts/theme-studio/app_inventory.py
index ed904b119..11ca605d1 100644
--- a/scripts/theme-studio/app_inventory.py
+++ b/scripts/theme-studio/app_inventory.py
@@ -7,33 +7,14 @@ import os
from collections.abc import Sequence
from typing import Any
+from face_data import BESPOKE_APP_SPECS
-BESPOKE_APPS = {
- "magit",
- "elfeed",
- "org",
- "org-mode",
- "mu4e",
- "gnus",
- "org-faces",
- "ghostel",
- "auto-dim-other-buffers",
- "dashboard",
- "lsp-mode",
- "git-gutter",
- "flycheck",
- "dired",
- "dirvish",
- "calibredb",
- "erc",
- "org-drill",
- "org-noter",
- "signel",
- "pearl",
- "slack",
- "telega",
- "shr",
-}
+
+# Keys of the bespoke apps (single-sourced in face_data), excluded from the
+# generic-inventory path so they aren't also emitted as plain inventory apps.
+# "org" is an explicit alias of the "org-mode" bespoke app, so an inventory
+# package literally named "org" never gets a duplicate generic entry.
+BESPOKE_APPS = {spec[0] for spec in BESPOKE_APP_SPECS} | {"org"}
# Inventory apps (not in BESPOKE_APPS) default to the generic preview. A few have