> one thing i really like about emacs is i still use the shell (awk/sed/ag/etc) for a lot of tasks, and since i can use the shell inside an emacs buffer, copying-pasting out of them are incredibly easy, replacing my tmux usage.
I mainly use vim and what I normally do to use shell within vim is to open another window and run something like:
:r !some-shell-command
If I want to filter text within the buffer to the shell command, I can visually highlight it and run.
:'<,'> !some-other-command
It's easy enough to undo the result and retry. I can edit the shell command opening the command line window with q: (which allows me to browse through my ex command history and use standard vim keybindings to edit, copy, and paste parts of the commands from the history that I need to run them again.
I know you can do something similar in emacs using the M-! keybinding, but I'm sure that's not an orthodox way of doing things in that environment.
Sure it is, via C-u M-! . I'm not sure what you mean by "orthodox", but that's part of the standard configuration, so I have to consider that whatever Emacs orthodoxy there is must include it.
I mainly use vim and what I normally do to use shell within vim is to open another window and run something like:
If I want to filter text within the buffer to the shell command, I can visually highlight it and run. It's easy enough to undo the result and retry. I can edit the shell command opening the command line window with q: (which allows me to browse through my ex command history and use standard vim keybindings to edit, copy, and paste parts of the commands from the history that I need to run them again.I know you can do something similar in emacs using the M-! keybinding, but I'm sure that's not an orthodox way of doing things in that environment.