;;; org-yt.el --- Watch & Download Videos -*- lexical-binding: t; -*- ;; Copyright (C) 2023 Thanos Apollo ;; Author: Thanos Apollo ;; Keywords: extensions ;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation, either version 3 of the License, or ;; (at your option) any later version. ;; This program is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with this program. If not, see . ;;; Commentary: ;; ;;; Code: ;; TODO: play a video link using a video player from an org-mode read only buffer ;; TODO: Search Youtube videos play them using a video player ;; TODO: Download videos using yt-dlp ;; TODO: let user decide custom name and path (defun yt-download-video () "Download using link at point in an `'org-mode buffer with yt-dlp." (interactive) (let ((url (org-element-property :raw-link (org-element-context)))) (when (string-prefix-p "http" url) (async-shell-command (format "yt-dlp %s" url)) (message "Downloading %s " url)))) (provide 'org-yt) ;;; org-yt.el ends here