newsboat improvements

This commit is contained in:
Noah Masur 2021-11-25 14:40:15 -05:00
parent 154fe2917b
commit f025413ad1
4 changed files with 29 additions and 2 deletions

15
bin/bookmark Executable file
View File

@ -0,0 +1,15 @@
#!/bin/sh
URL=$1
TITLE=$2
DESCRIPTION=$3
FEED=$4
printf "\n\n## [%s](%s)\n%s\nFrom %s: added on [%s](%s.md).\n\n---\n" \
"$TITLE" \
"$URL" \
"$DESCRIPTION" \
"$FEED" \
"$TODAY_NOTE" \
"$TODAY_NOTE" \
>>"$NOTES_PATH/bookmarks.md"

1
mpv.configlink/mpv.conf Normal file
View File

@ -0,0 +1 @@
script-opts=ytdl_hook-ytdl_path=/usr/local/bin/yt-dlp

View File

@ -1,4 +1,7 @@
browser "$BROWSER %u" browser "$BROWSER %u"
prepopulate-query-feeds yes
feed-sort-order lastupdated
reload-only-visible-feeds yes
bind-key j down bind-key j down
bind-key k up bind-key k up
@ -12,9 +15,16 @@ bind-key n next-unread
bind-key p prev-unread bind-key p prev-unread
bind-key ; macro-prefix bind-key ; macro-prefix
bind-key B bookmark bind-key B bookmark
bind-key N toggle-article-read bind-key f edit-flags
macro v set browser "mpv %u"; open-in-browser; set browser "$BROWSER %u" macro v set browser "mpv %u"; open-in-browser; set browser "$BROWSER %u"
macro h set browser "clx view $(echo %u | cut -d '=' -f2)"; one; set browser "$BROWSER %u" macro h set browser "clx view $(echo %u | cut -d '=' -f2)"; one; set browser "$BROWSER %u"
macro w set browser "w3m -o confirm_qq=false %u"; open-in-browser; set browser "$BROWSER %u" macro w set browser "w3m -o confirm_qq=false %u"; open-in-browser; set browser "$BROWSER %u"
macro r set browser "url-markdown %u | glow -p -w 72 -"; open-in-browser; set browser "$BROWSER %u" macro r set browser "url-markdown %u | glow -p -w 72 -"; open-in-browser; set browser "$BROWSER %u"
macro d set browser "youtube-dl -o "~/Downloads/%(title)s.%(ext)s" %u &"; open-in-browser-noninteractively; set browser "$BROWSER %u"
macro n set-tag News; reload-all
macro q set-tag All
macro e set-tag Reddit; reload-all
macro e set-tag YouTube; reload-all
bookmark-cmd "bookmark"

View File

@ -1,6 +1,7 @@
#!/bin/sh #!/bin/sh
echo "downloading ytfzf" echo "downloading ytfzf"
curl -sL "https://raw.githubusercontent.com/pystardust/ytfzf/master/ytfzf" > ~/.local/bin/ytfzf mkdir -p ~/.local/bin
curl -sL "https://raw.githubusercontent.com/pystardust/ytfzf/master/ytfzf" >~/.local/bin/ytfzf
chmod 755 ~/.local/bin/ytfzf chmod 755 ~/.local/bin/ytfzf
echo "ytfzf ✓" echo "ytfzf ✓"