adding some tweaks i guess
This commit is contained in:
parent
458911f139
commit
acd99a5c59
3 changed files with 95 additions and 13 deletions
37
README.org
37
README.org
|
@ -265,9 +265,9 @@ Probably the prettiest and best modeline I've found.
|
|||
:ensure t
|
||||
:init
|
||||
(doom-modeline-mode 1)
|
||||
(setq doom-modeline-height 30
|
||||
(setq doom-modeline-height 25
|
||||
doom-modeline-bar-width 3
|
||||
all-the-icons-scale-factor 1.0
|
||||
all-the-icons-scale-factor 0.9
|
||||
doom-modeline-hud nil
|
||||
doom-modeline-buffer-file-name-style 'file-name
|
||||
doom-modeline-buffer-encoding nil
|
||||
|
@ -1814,6 +1814,7 @@ These two packages created by Prot are interesting to me and may help to make su
|
|||
Builtin webbrowser for emacs. Trying it out as a text only browser for things.
|
||||
|
||||
#+begin_src emacs-lisp
|
||||
(setq home-directory "~/")
|
||||
(defun chris/eww-mpv ()
|
||||
"Launch the url in mpv"
|
||||
(interactive)
|
||||
|
@ -1826,11 +1827,39 @@ Builtin webbrowser for emacs. Trying it out as a text only browser for things.
|
|||
(goto-char pt)
|
||||
(let ((url (get-text-property (point) 'shr-url)))
|
||||
(if (start-process "mpv" "mpv-output" "mpv" url)
|
||||
(message (concat"mpv started => " url))
|
||||
(message (concat "mpv started => " url))
|
||||
(message "mpv failed, maybe this isn't a link?"))))))
|
||||
|
||||
;; (defun chris/)
|
||||
|
||||
(defun chris/eww-video-dl ()
|
||||
"Download the video at the url"
|
||||
(interactive)
|
||||
(let ((pt (avy-with ace-link-eww
|
||||
(avy-process
|
||||
(mapcar #'cdr (ace-link--eww-collect))
|
||||
(avy--style-fn avy-style)))))
|
||||
|
||||
(when (number-or-marker-p pt)
|
||||
(goto-char pt)
|
||||
(let ((url (get-text-property (point) 'shr-url)))
|
||||
(if (start-process
|
||||
"yt-dlp"
|
||||
"yt-dlp-output"
|
||||
"yt-dlp" "-o" (concat home-directory "Videos/%(title)s.%(ext)s") url)
|
||||
(message (concat "downloading => " url))
|
||||
(message "idk this failed I guess..."))
|
||||
(pop-to-buffer "yt-dlp-output")
|
||||
(comint-mode)
|
||||
(evil-normal-state)
|
||||
(general-def 'normal comint-mode-map
|
||||
"q" 'kill-buffer-and-window)))))
|
||||
|
||||
(setq eww-search-prefix "https://search.tfcconnection.org/search?q=")
|
||||
|
||||
(general-def 'normal eww-mode-map
|
||||
"gv" 'chris/eww-mpv)
|
||||
"gv" 'chris/eww-mpv
|
||||
"gV" 'chris/eww-video-dl)
|
||||
#+end_src
|
||||
|
||||
** Completion
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue