aboutsummaryrefslogtreecommitdiff
path: root/tests/test-org-drill-config--drill-files-or-error.el
Commit message (Collapse)AuthorAgeFilesLines
* refactor(org-drill): share one validated drill-file selectorCraig Jennings13 days1-0/+56
org-capture-config.el and org-drill-config.el each scanned drill-dir with an inline directory-files call, so a missing, empty, or unreadable drill-dir surfaced as a low-level directory-files error or an empty completing-read, depending on which command ran. Added cj/--drill-files-or-error, the single validated entry point: it signals a clear user-error when the directory is missing, unreadable, or has no drill files, and otherwise returns the list. cj/--drill-pick-file and both drill capture templates now route through it. The pure cj/--drill-files-in primitive and its tests are unchanged. Tests cover missing dir, empty dir, a non-org-only dir, and a normal listing.