diff --git a/.config/qutebrowser/config.py b/.config/qutebrowser/config.py index 6d461f9..ce22e40 100644 --- a/.config/qutebrowser/config.py +++ b/.config/qutebrowser/config.py @@ -116,8 +116,11 @@ c.aliases["e"] = "session-load" # bookmarklet aliases: # currently the idea is to prefix bookmarklets with b (as in open "bookmarklet") # wallabag add current page, either with walla command, or bw -c.aliases["wallabag-add"] = "spawn --userscript wallabag_add.sh" -config.bind(leader + 'bw', 'wallabag-add', mode='normal') +c.aliases["add-wallabag"] = "spawn --userscript wallabag_add.sh" +config.bind(leader + 'bw', 'add-wallabag', mode='normal') +# add to (my) shaarli instance +c.aliases["add-shaarli"] = "spawn --userscript shaarli_add.sh" +config.bind(leader + 'bs', 'add-shaarli', mode='normal') # re-opens the current page on the web archive overview page c.aliases["archive-open"] = "open https://web.archive.org/web/{url}" config.bind(leader + 'ba', 'archive-open', mode='normal') diff --git a/.local/share/qutebrowser/userscripts/shaarli_add.sh b/.local/share/qutebrowser/userscripts/shaarli_add.sh new file mode 100755 index 0000000..01660af --- /dev/null +++ b/.local/share/qutebrowser/userscripts/shaarli_add.sh @@ -0,0 +1,4 @@ +#! /usr/bin/bash + +# send current page to my personal shaarli instance and open the 'post' page to edit it +echo "open https://links.martyoeh.me/?post=$QUTE_URL" >>"$QUTE_FIFO"