-
Notifications
You must be signed in to change notification settings - Fork 227
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature for putting output back into vim #90
Comments
Hi there, "easy way" … I don't think so, unless I've missed something. When we paste text to tmux, it just flushes it in the input buffer (as if you had typed it yourself)… but what happens (the feedback) is a result of whatever is running. I can imagine doing a snapshot before, a snapshot after, and diff both -- taking that as the "result" of the command you just ran. I'm not sure how easy/hard that would be … or whether it would be useful at all. In what context do you need to copy the result back in vim? (maybe there are other ways) |
Ah I see, yeah there weren't any easy ways that came to my mind either. I have a ipython session pane open alongside a vim pane in tmux, and I've gotten into the habit of pasting the results of snippets of python evaluations back into vim to remind me of how I developed a function (kind of like really lazy tdd). Maybe wrapping the contents of what you send into tmux with a session (bash, ipython, ghci etc.) specific callback that sends the output back to tmux to give back to the vim pane? Does that sound like something that might work - I don't mind spending some time looking into this if you think it's plausible! Eddie |
You can feed and read back a command with the It's similar to what happens when you select a block of text and feed it to python:
|
Hmm do you think there might be a way to preserve the environment of the interpreter (e.g. previously defined variables etc.) between |
no, not really :-( |
Loving using this plugin, although I was wondering if there's an easy way to send the results of the evaluation back into the vim buffer automatically? I'm using this with tmux at the minute and am finding that switching over to the tmux pane, copy the output, switching back to paste it in getting a bit tedious.
The text was updated successfully, but these errors were encountered: