You are not logged in.
Hi there,
Not too long ago, I toyed with xterm to make URL selection somewhat similar to urxvt's with url-select. https://bbs.archlinux.org/viewtopic.php?id=181515
Not too satisfied because it requires compiling xterm, I found a simpler solution. First off, you need this little script. I called it grab-urls:
#!/bin/bash
regex='\bhttps?://[^ ]*\b'
function menu { dmenu -p 'Open URL' ; }
function open { dwb -n "$1" ; }
urls="$(grep -Eo "$regex")"
[ -z "$urls" ] && exit
url="$(echo "$urls" | tac | menu)"
[ -n "$url" ] && open "$url"
Next, the trick is to have xterm pipe the content of its scrollback to that script. In your .Xresources:
xterm*printerCommand: /path/to/grab-urls
*VT100.Translations: #override \n\
Alt <Key>u: print-everything(noAttrs, noNewLine)
After sourcing it with xrdb and restarting xterm, pressing Alt+u should spawn dmenu with the links it found.
This is nothing too fancy, but I thought I'd share it.
Offline