summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThanos Apollo <[email protected]>2023-10-13 16:07:10 +0300
committerThanos Apollo <[email protected]>2023-10-13 16:07:10 +0300
commit0509f298cbd87141a865890ea78295bdce59d33e (patch)
tree161064c77b076b48468c456a609839cb4da6b3a8
parentb1d69778cb8467b5a426b42f083d049d8b9e058b (diff)
yeetube-mpv-play-url: Rename to yeetube-mpv-play
This function is not specific to just playing urls. User may make custom functions to play local files with it, thus the change of name.
-rw-r--r--README.md2
-rw-r--r--yeetube-mpv.el9
-rw-r--r--yeetube.el2
3 files changed, 8 insertions, 5 deletions
diff --git a/README.md b/README.md
index 6998ecf..f06c3d8 100644
--- a/README.md
+++ b/README.md
@@ -62,7 +62,7 @@ $ sudo apt install mpv yt-dlp
## Configuration
### Media Player
-By default `yeetube-player` is set to `yeetube-mpv-play-url`, you can
+By default `yeetube-player` is set to `yeetube-mpv-play`, you can
use [mpv.el](https://github.com/kljohann/mpv.el),
[GNU/Emms](https://www.gnu.org/software/emms/) or other similar
packages like so:
diff --git a/yeetube-mpv.el b/yeetube-mpv.el
index 6c59552..22c78ae 100644
--- a/yeetube-mpv.el
+++ b/yeetube-mpv.el
@@ -50,11 +50,14 @@
(start-process-shell-command
"yeetube" nil command))))
-(defun yeetube-mpv-play-url (url)
- "Start yeetube process to play URL using mpv."
+(defun yeetube-mpv-play (input)
+ "Start yeetube process to play INPUT using mpv.
+
+This function is not specific to just playing urls. Feel free to use
+to play local files."
(yeetube-mpv-process
(concat yeetube-mpv-path " "
- (shell-quote-argument url)
+ (shell-quote-argument input)
(when yeetube-mpv-disable-video " --no-video")))
(message "yeetube: starting mpv process"))
diff --git a/yeetube.el b/yeetube.el
index 3b41587..6d4f898 100644
--- a/yeetube.el
+++ b/yeetube.el
@@ -53,7 +53,7 @@
:type 'natnump
:group 'yeetube)
-(defcustom yeetube-player #'yeetube-mpv-play-url
+(defcustom yeetube-player #'yeetube-mpv-play
"Select media player function."
:type 'function
:group 'yeetube)