Yanking URLs in w3m¶
Set the External Browser option
Method One¶
sh -c 'printf %s "$0" | xsel'
You can use xsel -b
to use the clipboard instead of the primary
selection. An alternative to
xsel is
xclip (xclip
for the primary
selection, xclip -selection CLIPBOARD
for the clipboard).
In ~/.w3m/config
, that’s the extbrowser
setting.
Then press M to
copy (yank) the URL of the current page, or ESC M
to copy the URL of
the link under the cursor.
You can use the second or third external browser for that instead; then
the key combination is 2 M
or 3 M
or 2 ESC M
or 3 ESC M
.
Method Two¶
you can yank url vim style, supports tmux,linux,macos,windows,android
$EDITOR ~/.w3m/keymap
usage: go to a link and press **yy** to copy url
yank url to multiple clipboard (under cursor)¶
1 |
|
yank url to multiple clipboard (current page)¶
1 |
|
Last update:
Feb 14, 2025