We Recommend

Beginning Ruby: From Novice to Professional Beginning Ruby: From Novice to Professional
Beginning Ruby is a thoroughly contemporary guide for every type of reader wanting to learn Ruby, from novice programmers to web developers to Ruby newcomers. It starts by explaining the principles behind object-oriented programming and within a few chapters builds toward creating a genuine Ruby application.


Posted By

vanne on 06/27/07


Tagged

ruby windows irb


Versions (?)


IRB clear screen on windows


Published in: Ruby 


URL: http://www.stephenchu.com/2006/09/enhance-your-irb-experience-on-windows.html

Since there is no convenient way to clear the console in irb on windows, we can simple emulate the dos cls function

  1. # throw this inside %userprofile%\.irbrc and you're good
  2. def cls
  3. system('cls')
  4. end

Report this snippet 

You need to login to post a comment.