emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/mpv e3fad297cd 18/50: add README.md


From: ELPA Syncer
Subject: [nongnu] elpa/mpv e3fad297cd 18/50: add README.md
Date: Tue, 28 Dec 2021 00:58:40 -0500 (EST)

branch: elpa/mpv
commit e3fad297cd68719b8573bd326b01bbdf20ef4a87
Author: Johann Klähn <kljohann@gmail.com>
Commit: Johann Klähn <kljohann@gmail.com>

    add README.md
---
 README.md | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/README.md b/README.md
new file mode 100644
index 0000000000..2bf926a46c
--- /dev/null
+++ b/README.md
@@ -0,0 +1,31 @@
+# mpv.el
+
+This package is a potpourri of helper functions to control a [mpv][]
+process via its IPC interface.  After installing you might want to add
+some of the following to your init file to ease transcription of videos
+using Org-mode:
+
+```emacs
+(defun org-timer-item--mpv-insert-playback-position (fun &rest args)
+  "When no org timer is running but mpv is alive, insert playback position."
+  (if (and
+       (not org-timer-start-time)
+       (mpv--alive-p))
+      (mpv-insert-playback-position t)
+    (apply fun args)))
+(advice-add 'org-timer-item :around
+            #'org-timer-item--mpv-insert-playback-position)
+
+(org-add-link-type "mpv" #'mpv-play)
+(defun org-mpv-complete-link (&optional arg)
+  (replace-regexp-in-string
+   "file:" "mpv:"
+   (org-file-complete-link arg)
+   t t))
+(add-hook 'org-open-at-point-functions #'mpv-seek-to-position-at-point)
+```
+
+Apart from that, just have a look at the interactive functions in
+[mpv.el](mpv.el).
+
+[mpv]: http://mpv.io/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]