introduced tmux_conf_urlscan_options to configure urlscan invocation, resolves #745
This commit is contained in:
parent
dc88d389a2
commit
cd3744965a
26
.tmux.conf
26
.tmux.conf
|
@ -101,11 +101,6 @@ bind Tab last-window # move to last active window
|
|||
bind m run "cut -c3- '#{TMUX_CONF}' | sh -s _toggle_mouse"
|
||||
|
||||
|
||||
# -- urlview -------------------------------------------------------------------
|
||||
|
||||
bind U run "cut -c3- '#{TMUX_CONF}' | sh -s _urlview '#{pane_id}'"
|
||||
|
||||
|
||||
# -- facebook pathpicker -------------------------------------------------------
|
||||
|
||||
bind F run "cut -c3- '#{TMUX_CONF}' | sh -s _fpp '#{pane_id}' '#{pane_current_path}'"
|
||||
|
@ -991,6 +986,13 @@ run 'cut -c3- "$TMUX_CONF" | sh -s _apply_configuration'
|
|||
# perl -n -i -e "if ($. != $line) { print }" "$cfg.in"
|
||||
# done
|
||||
# fi
|
||||
#
|
||||
# tmux_conf_urlscan_options=${tmux_conf_urlscan_options:---compact --dedupe}
|
||||
# if command -v urlscan > /dev/null 2>&1; then
|
||||
# tmux bind U run "cut -c3- '#{TMUX_CONF}' | sh -s _urlscan '#{pane_id}' $tmux_conf_urlscan_options"
|
||||
# elif command -v urlview > /dev/null 2>&1; then
|
||||
# tmux bind U run "cut -c3- '#{TMUX_CONF}' | sh -s _urlview '#{pane_id}'"
|
||||
# fi
|
||||
# }
|
||||
#
|
||||
# _apply_theme() {
|
||||
|
@ -1714,11 +1716,15 @@ run 'cut -c3- "$TMUX_CONF" | sh -s _apply_configuration'
|
|||
# }
|
||||
#
|
||||
# _urlview() {
|
||||
# tmux capture-pane -J -S - -E - -b "urlview-$1" -t "$1"
|
||||
# command='false'
|
||||
# command -v urlview > /dev/null 2>&1 && command='urlview'
|
||||
# command -v urlscan > /dev/null 2>&1 && command='urlscan --compact --dedupe'
|
||||
# tmux split-window "'$TMUX_PROGRAM' ${TMUX_SOCKET:+-S "$TMUX_SOCKET"} show-buffer -b 'urlview-$1' | $command || true; '$TMUX_PROGRAM' ${TMUX_SOCKET:+-S "$TMUX_SOCKET"} delete-buffer -b 'urlview-$1'"
|
||||
# pane_id="$1"; shift
|
||||
# tmux capture-pane -J -S - -E - -b "urlview-$pane_id" -t "$pane_id"
|
||||
# tmux split-window "'$TMUX_PROGRAM' ${TMUX_SOCKET:+-S "$TMUX_SOCKET"} show-buffer -b 'urlview-$pane_id' | urlview || true; '$TMUX_PROGRAM' ${TMUX_SOCKET:+-S "$TMUX_SOCKET"} delete-buffer -b 'urlview-$pane_id'"
|
||||
# }
|
||||
#
|
||||
# _urlscan() {
|
||||
# pane_id="$1"; shift
|
||||
# tmux capture-pane -J -S - -E - -b "urlscan-$pane_id" -t "$pane_id"
|
||||
# tmux split-window "'$TMUX_PROGRAM' ${TMUX_SOCKET:+-S "$TMUX_SOCKET"} show-buffer -b 'urlscan-$pane_id' | urlscan $* || true; '$TMUX_PROGRAM' ${TMUX_SOCKET:+-S "$TMUX_SOCKET"} delete-buffer -b 'urlscan-$pane_id'"
|
||||
# }
|
||||
#
|
||||
# _fpp() {
|
||||
|
|
|
@ -364,6 +364,12 @@ tmux_conf_theme_clock_style="24"
|
|||
tmux_conf_copy_to_os_clipboard=false
|
||||
|
||||
|
||||
# -- urlscan -------------------------------------------------------------------
|
||||
|
||||
# options passed to urlscan
|
||||
tmux_conf_urlscan_options="--compact --dedupe"
|
||||
|
||||
|
||||
# -- user customizations -------------------------------------------------------
|
||||
|
||||
# this is the place to override or undo settings
|
||||
|
|
Loading…
Reference in a new issue