-2

I was watching a tutorial in which instructor using vim for ruby on rials development. He writes code on blank screen and then uses command :w hello.rb the whole code behaves like ruby code... when i try to use this command it gives an error message. I searched a lot on stackoverflow.com There are some similar questions but no one works... http://vim.wikia.com/wiki/Saving_a_file and Vim Can't Save File (E212) and one solutions is :w!! but i want to save file as :w filename e.g :w hello.rb

Community
  • 1
  • 1
Rana Zubair
  • 189
  • 1
  • 3
  • 15

1 Answers1

1

Try using the following (after pressing escape) :wq! Should work.

Joe
  • 2,386
  • 1
  • 22
  • 33