Emacs equivalent of this Vim command to run my tests?
- by eightbitraptor
I'm using Emacs at the moment and experimenting with it for my Rails development and there is one thing that I do quite regularly in Vim and I'd like to know if an equivalent exists in Emacs, or an alternative workflow to achieve the behavior that I need.
The command in Vim is
:map ;t :!rspec --no-color %<cr>
Essentially this maps a key combination to run a bash/shell command on the file represented by the current buffer (% expands to the filename at runtime, the <cr> is just a carriage return at the end to execute the command).
I map all sorts of random little commands as and when I need them and I really miss the immediacy of this approach.
How can I achieve something similar?