Add urlscan as alternative to urlview
Since urlview is not available with pacman but urlscan is, first check and integrate urlscan then fallback to urlview.
This commit is contained in:
parent
cabd57ae84
commit
20be7f3bcc
@ -11,6 +11,7 @@
|
|||||||
- pacman:
|
- pacman:
|
||||||
- tmux
|
- tmux
|
||||||
- xclip
|
- xclip
|
||||||
|
- urlscan
|
||||||
- symlink:
|
- symlink:
|
||||||
- {src: tmux.conf, dst: ~/.tmux.conf}
|
- {src: tmux.conf, dst: ~/.tmux.conf}
|
||||||
- {src: layouts/session-main, dst: ~/.local/share/tmux/layouts/session-main}
|
- {src: layouts/session-main, dst: ~/.local/share/tmux/layouts/session-main}
|
||||||
|
@ -69,8 +69,10 @@ bind -n C-k if $in_vim 'send-keys C-k' 'select-pane -U'
|
|||||||
bind -n C-l if $in_vim 'send-keys C-l' 'select-pane -R'
|
bind -n C-l if $in_vim 'send-keys C-l' 'select-pane -R'
|
||||||
bind -n C-\ if $in_vim 'send-keys C-\\' 'select-pane -l'
|
bind -n C-\ if $in_vim 'send-keys C-\\' 'select-pane -l'
|
||||||
|
|
||||||
# Integrate urlview
|
# Integrate urlscan or fallback to urlview
|
||||||
bind u capture-pane \; split-window 'tmux show-buffer | urlview -'
|
if -b 'which urlscan' \
|
||||||
|
'bind u capture-pane \; split-window "tmux show-buffer | urlscan"' \
|
||||||
|
'bind u capture-pane \; split-window "tmux show-buffer | urlview -"'
|
||||||
|
|
||||||
# Unbind copy mode defaults so pane selection works
|
# Unbind copy mode defaults so pane selection works
|
||||||
unbind -T copy-mode-vi C-h
|
unbind -T copy-mode-vi C-h
|
||||||
|
Loading…
x
Reference in New Issue
Block a user