You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be really great if it was possible to send any text object to REPL. For example, if I bind this function to gs, I would be able to send 3 lines with gs2j, or 2 paragraphs with gs2ap. Or if I have a text object for entire buffer ae, I could type gsae to send the buffer.
I've come up with this:
" Send text object to tmux pane via slimuxnnoremap<silent>gs:<C-u>set opfunc=SlimuxREPLSendTextObject<CR>g@nnoremap<silent>gss:SlimuxREPLSendLine<CR>vnoremap<silent>gs:SlimuxREPLSendSelection<CR>function!SlimuxREPLSendTextObject(type, ...) abortlet saved_unnamed_register =@@silentexe"normal! '[V']y"'[,']SlimuxREPLSendSelection
let@@= saved_unnamed_register
endfunction
Note that it does not work with sub-line text objects, like iw.
The text was updated successfully, but these errors were encountered:
It would be really great if it was possible to send any text object to REPL. For example, if I bind this function to
gs
, I would be able to send 3 lines withgs2j
, or 2 paragraphs withgs2ap
. Or if I have a text object for entire bufferae
, I could typegsae
to send the buffer.I've come up with this:
Note that it does not work with sub-line text objects, like
iw
.The text was updated successfully, but these errors were encountered: