diff options
-rw-r--r-- | init.org | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -1439,7 +1439,12 @@ "infoq.com") t))) - (defun jao-video--url-p (url) (string-match-p jao-video--url-rx url)) + (defvar jao-video--ext-rx + (format "^https?://.+/.+\\.%s" (regexp-opt '("mp3" "webm" "mp4")))) + + (defun jao-video--url-p (url) + (or (string-match-p jao-video--url-rx url) + (string-match-p jao-video--ext-rx url))) (defun jao--remote-run (url prg) (let ((args (format "%s %s" prg (shell-quote-argument url)))) |