From a2657993bad828af6743c68931a0e848bfcdec53 Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Sun, 21 Nov 2021 23:57:41 -0600 Subject: I DECLARE BANKRUPTCY ... 8 Didn't think to do this till pretty .. written, so here we are. --- lisp/acdw-ytel.el | 75 ------------------------------------------------------- 1 file changed, 75 deletions(-) delete mode 100644 lisp/acdw-ytel.el (limited to 'lisp/acdw-ytel.el') diff --git a/lisp/acdw-ytel.el b/lisp/acdw-ytel.el deleted file mode 100644 index 276323d..0000000 --- a/lisp/acdw-ytel.el +++ /dev/null @@ -1,75 +0,0 @@ -;;; acdw-ytel.el --- bespoke functions for ytel -*- lexical-binding: t -*- - -;;; Commentary: - -;; Extra code for the ytel package: -;; https://github.com/gRastello/ytel - -;;; Code: - -(require 'ytel nil t) - -(defun acdw/ytel-current-video-link () - "Get the link of the video at point." - (let* ((video (ytel-get-current-video)) - (id (ytel-video-id video))) - (concat "https://www.youtube.com/watch?v=" id))) - -(defun acdw/ytel-watch () ; This could possibly use `browse-url'. - "Stream video at point in mpv." - (interactive) - (start-process "ytel mpv" nil - "mpv" - (acdw/ytel-current-video-link) - "--ytdl-format=bestvideo[height<=?720]+bestaudio/best") - (message "Starting streaming...")) - -(defun acdw/ytel-copy-link () - "Copy link of the video at point." - (interactive) - (let ((link (acdw/ytel-current-video-link))) - (kill-new link) - (message "Copied %s to kill-ring" link))) - - -;;; YTDIOUS: https://github.com/spiderbit/ytdious -;; a fork of ytel that uses table-view or w/e. looks nicer - -(require 'ytdious nil t) - -(defun acdw/ytdious-current-video-link () - "Get the link of the video at point." - (let* ((video (ytdious-get-current-video)) - (id (ytdious-video-id-fun video))) - (concat "https://www.youtube.com/watch?v=" id))) - -(defun acdw/ytdious-watch () ; This could possibly use `browse-url'. - "Stream video at point in mpv." - (interactive) - (let ((link (acdw/ytdious-current-video-link))) - (start-process "ytdious mpv" nil - "mpv" - link - "--ytdl-format=bestvideo[height<=?720]+bestaudio/best") - (message "Streaming %s..." link))) - -(defun acdw/ytdious-copy-link () - "Copy link of the video at point." - (interactive) - (let ((link (acdw/ytdious-current-video-link))) - (kill-new link) - (message "Copied %s to kill-ring" link))) - -(defun acdw/ytdious-quit () - "Quit ytdious." - ;; This corrects an error with `ytdious-quit' where it doesn't have the right - ;; buffer setup. - (interactive) - (quit-window)) - -;;; Ignore `ytdious-show-image-asyncron' because it's buggy. - -(defalias 'ytdious-show-image-asyncron #'ignore) - -(provide 'acdw-ytel) -;;; acdw-ytel.el ends here -- cgit 1.4.1-21-gabe81