aboutsummaryrefslogtreecommitdiff
path: root/modules/external-open.el
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-05-12 04:45:47 -0500
committerCraig Jennings <c@cjennings.net>2026-05-12 04:45:47 -0500
commit2063e9dffff751d5f2cbca2817aee5daaa463cf3 (patch)
tree3d28ded2516c2e0b31dd2f00a852ab5fe9dfac69 /modules/external-open.el
parent839bbeb14a92a777a3857102dba08a212b21443d (diff)
downloaddotemacs-2063e9dffff751d5f2cbca2817aee5daaa463cf3.tar.gz
dotemacs-2063e9dffff751d5f2cbca2817aee5daaa463cf3.zip
feat(dirvish): print the file at point with P
`P' in dirvish/dired now runs `cj/dirvish-print-file': it sends the file at point to the default printer via CUPS (`lp', falling back to `lpr'), after a confirmation prompt. It refuses directories and file types outside `cj/dirvish-print-extensions' (pdf, txt, org, images, source files, ...). CUPS filters handle PDFs directly, so `lp <file>' covers everything in the list, and no separate print dialog is needed. `P' was the project/home-relative variant of `cj/dired-copy-path-as-kill', now dropped (the `p' absolute-path and `l' org-link bindings stay, and `M-x cj/dired-copy-path-as-kill' still works). Plain dired's built-in `P' was `dired-do-print', which `dirvish-mode-map' had already shadowed, so this just replaces it with a type-aware version. Tests cover the predicates and the command's confirm / decline / no-file / directory / non-printable / no-printer / print-failure paths.
Diffstat (limited to 'modules/external-open.el')
0 files changed, 0 insertions, 0 deletions