On Tue, May 30, 2006 at 08:40:33PM +0900, Peñá, Botp wrote: > > Sample cross-referenced report generated by rcov: > > http://eigenclass.org/static/rcov-sample-report-crossref/ > > uber cool. > i think the only thing lacking is a web-based editor that hooks to rcov. > Wherein you can click on any source, edit it, rerun rcov analysis again, all > just using a browser.. Attractive at first sight, but on second thought I don't think anybody would enjoy editing with a browser (unless running an embedded vim or browsing with emacs) :-) I'll think about integration with the user's editor of choice. > > This release is the first to include RubyGems packages: both a binary one > > for Win32 and a platform-independent one for all those with a compiler, > > (or a lot of patience, if willing to run rcov in pure-Ruby mode), so > > gem install rcov > > should work. > > tested and runs great in windows and linux. > but i would still love to see a pure ruby rcov (even if it may be slow). Actually, rcov *will* run in pure-Ruby mode if it cannot load rcovrt. If you install it from the tarball with ruby setup.rb --without-ext or using RubyGems and the compilation fails, it'll fall back to pure-Ruby and give you a warning: batsman@tux-chan:~/src/rcov/examples$ rcov --version bash: rcov: command not found batsman@tux-chan:~/src/rcov/examples$ make=bogus-command-foo gem install rcov Attempting local installation of 'rcov' Local gem file not found: rcov*.gem Attempting remote installation of 'rcov' Select which gem to install for your platform (i686-linux) 1. rcov 0.5.0.1 (ruby) 2. rcov 0.5.0.1 (mswin32) 3. Cancel installation > 1 Building native extensions. This could take a while... /home/batsman/usr/lib/ruby/1.8/fileutils.rb:243: command not found: bogus-command-foo /home/batsman/usr/lib/ruby/1.8/fileutils.rb:243: command not found: bogus-command-foo install ruby extconf.rb install rcov creating Makefile bogus-command-foo bogus-command-foo install Successfully installed rcov-0.5.0.1 Installing RDoc documentation for rcov-0.5.0.1... batsman@tux-chan:~/src/rcov/examples$ rcov --version rcov 0.5.0 2006-05-30 batsman@tux-chan:~/src/rcov/examples$ rcov --text-coverage --no-html --no-color a.rb Since the rcovrt extension couldn't be loaded, rcov will run in pure-Ruby mode, which is about two orders of magnitude slower. If you're on win32, you can find a pre-built extension (usable with recent One Click Installer and mswin32 builds) at http://eigenclass.org/hiki.rb?rcov . blergh yep Done: 56 ================================================================================ a.rb ================================================================================ srand(0) c = 0 d = 1 10.times do |i| if rand % (i + 10) c += i d += 1 end end puts "blergh" if c > 4*d # stuff puts "yep" ## else ## puts "nope" ## # more stuff ## end puts "Done: #{c+d}" -- Mauricio Fernandez - http://eigenclass.org - singular Ruby