diff options
| author | Blake Romero <blake@blkrom.com> | 2025-10-19 13:24:47 +0100 |
|---|---|---|
| committer | Blake Romero <blake@blkrom.com> | 2025-10-19 14:43:31 +0100 |
| commit | 4da58271ca6713ba07e35d49b595c43b473a050d (patch) | |
| tree | f7fea4c26dae85ea48e623a8ad2b34d3226bdc6c | |
| parent | 052b6f9acdcca3610198f501798898786bbcf678 (diff) | |
| -rw-r--r-- | emacs-config.org | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/emacs-config.org b/emacs-config.org index ae690d2..0ef91f2 100644 --- a/emacs-config.org +++ b/emacs-config.org @@ -1160,7 +1160,24 @@ Command to review the weekend. org-agenda-custom-commands) #+end_src -*** Org Clock-table +*** Org Clock +Play org-clock sounds with ~ffplay~ if possible. +Requires =oxygen-sounds= system package. +#+begin_src elisp + (with-eval-after-load 'org-clock + (advice-add 'org-clock-play-sound :around + (lambda (cmd sound) + "Play sound with ffplay if available." + (if (file-exists-p sound) + (if (executable-find "ffplay") + (start-process "ffplay" nil + "ffplay" "-nodisp" "-autoexit" "-v" "-8" sound) + (apply cmd sound)) + (warn "Could not play file '%s'" sound)))) + (setq-default + org-clock-sound "/usr/share/sounds/oxygen/stereo/completion-success.ogg")) +#+end_src + Define a custom clocktable formatter function for ~+org-clocktable-format~. #+begin_src elisp (with-eval-after-load 'org-clock |
