diff --git a/bin/bookmark b/bin/bookmark new file mode 100755 index 0000000..9fb38bf --- /dev/null +++ b/bin/bookmark @@ -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" diff --git a/mpv.configlink/mpv.conf b/mpv.configlink/mpv.conf new file mode 100644 index 0000000..60ad7f9 --- /dev/null +++ b/mpv.configlink/mpv.conf @@ -0,0 +1 @@ +script-opts=ytdl_hook-ytdl_path=/usr/local/bin/yt-dlp diff --git a/newsboat.configlink/config b/newsboat.configlink/config index 9098869..836122d 100644 --- a/newsboat.configlink/config +++ b/newsboat.configlink/config @@ -1,4 +1,7 @@ browser "$BROWSER %u" +prepopulate-query-feeds yes +feed-sort-order lastupdated +reload-only-visible-feeds yes bind-key j down bind-key k up @@ -12,9 +15,16 @@ bind-key n next-unread bind-key p prev-unread bind-key ; macro-prefix 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 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 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" diff --git a/scripts/setup_ytfzf b/scripts/setup_ytfzf index 8c289c8..0408a3a 100755 --- a/scripts/setup_ytfzf +++ b/scripts/setup_ytfzf @@ -1,6 +1,7 @@ #!/bin/sh 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 echo "ytfzf ✓"