It has something to do with running the a TestUnit file i.e. it switches out of vim and runs the file.
:map ,t :w\|:!ruby test_spec.rb<cr>
Can someone break this command out with some explanation?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
saves the file
Let’s you input multiple commands, e.g.
:foo|:bar, is the same as:foo, hitting return,:bar. The\is to escape it in the map.Runs the shell command specified, in this case
ruby test_spec.rb.Carriage return (e.g. the enter or return key).
So when you hit ,t, it saves your file, and runs the command
ruby test_spec.rb.