Advertisement
Nickname
eigenclass
Registered since:
October 31, 2005
Short bio:
 
Home page:
http://eigenclass.org
Total posts:
358

Forum posts by Eigen Class:

24 pages [ Previous 1 ... 16 17 18 19 20 21 22 23 24 Next ]
Posted in All Buzz Forum, May 22, 2006, 1:50 PM
rcov 0.4.0 is really feature-packed, and (hopefully) less buggy than previous releases. This can be ascribed in large part to the use of rcov on itself to achieve better test coverage. Download it from rcov: code coverage for Ruby. The looks Starting with the most obvious changes, the XHTML output looks much better now with the new...
Posted in All Buzz Forum, May 18, 2006, 1:46 PM
I just began to eat my own dog food, applying rcov to its own regression tests. The coverage figure is still pathetic, but at least it's going up: rcov had been essentially untested (or only tested manually, which amounts to about the same) for way too long time. The main reason was bad laziness, and the self-justification that it's not easy to...
Posted in All Buzz Forum, May 15, 2006, 7:01 PM
ruby-talk:192757 reminded me of SuperStruct. I was going to reply with a pointer to that library, but I realized that the usual class MyClass < Struct.new(:a,:b) def initialize(*a) super # stuff end end idiom and SuperStruct still left an important part of the solution space uncovered. When you inherit from a Struct, the resulting class...
Posted in All Buzz Forum, May 11, 2006, 7:01 PM
I've been reworking my vim folding script for Ruby. It stays within the usability subspace I like (optimized vertical space, sensible foldtext, fold on classes, methods, etc.), but now it can also fold optionally on if/while and friends, and also supports folds set with markers. It is now available as a plugin, so installation is as easy as...
Posted in All Buzz Forum, May 10, 2006, 3:19 PM
There's more to benchmarking than slapping your code inside Benchmark.bm{|bm| bm.report("foo"){ ... } } The first thing we instinctively do is add TIMES.times with a large TIMES constant. Surely "errors" cancel each other out for large enough values of TIMES, right? But, how large is large enough? I wrote a simple AdaptativeBenchmark which...
Posted in All Buzz Forum, May 5, 2006, 11:20 AM
Driven by user feedback, rcov 0.3.0 introduces a number of features that simplify the analysis of Rails applications. Moreover, this is the first time a rcovrt binary for win32 (which makes rcov >100 times faster) is released simultaneously. The new code coverage analysis mode, --test-unit-only, records exclusively code executed inside...
Posted in All Buzz Forum, May 1, 2006, 3:30 PM
I had to transfer a few GB from a dying machine to an HFS+ partition; since I had the tarballs, it should have been a piece of cake, but: $ tar xvf bleh.tar programaci\363n/ tar: programaci\363n: Cannot mkdir: Invalid argument tar: Error exit delayed from previous errors The tarballs contain some ISO-8859_1-encoded filenames which are obviously...
Posted in All Buzz Forum, Apr 28, 2006, 5:28 PM
A quick & dirty run-and-show-output-in-vsplit-window script for vim. Definitely not as refined as the xmp decorator, and it cannot expand test assertions automagically, but I'll give it a try in my .vimrc. Some minor details to make it more palatable: works in insert, normal, visual mode, and DWIM doesn't overwrite the original file,...
Posted in All Buzz Forum, Apr 17, 2006, 1:58 PM
After writing a "pooling executor" that assigns tasks to a number of handlers in parallel, filtering referrer URLs somewhat efficiently becomes easier. Checking multiple referrers concurrently helps maximize bandwidth usage, which is quite important when you have to fetch ~8000 pages. Were this done serially, the process could easily take a...
Posted in All Buzz Forum, Apr 14, 2006, 5:59 PM
You might not have noticed it, but every page on eigenclass.org lists the most popular referrers. I often find interesting things in the Referer field, but unfortunately they are hard to find (especially for an occasional visitor) in the middle of unaccessible pages (bloglines, google reader, other online RSS aggregators...) and (as of late)...
Posted in All Buzz Forum, Apr 11, 2006, 11:57 AM
It is well known that the minimal space overhead for a non-immediate object in Ruby is 20 bytes*1. But the overhead will be much higher if your object happens to have instance variables (read: almost always). Take for instance class Stupid; attr_accessor :foo end class Stupid2; attr_accessor :foo, :bar end o1 = Stupid.new o1.foo = 1 o2 =...
Posted in All Buzz Forum, Apr 8, 2006, 8:27 PM
DATA is one of those features one rarely sees in use, but it can be quite handy at times. I used it in rcov to include the xx markup generation library while ensuring the rcov executable remained self-contained (the extension is optional). I've written a simple FS meant to be used with DATA, in order to structure it into individually accessible...
Posted in All Buzz Forum, Apr 3, 2006, 6:40 PM
It seems that building Ruby extensions under win32 is quite a daunting task: I've been asked repeatedly to provide win32 binaries for rcovrt (the extension that makes rcov's code coverage analysis run two orders of magnitude faster*1), so I cross-compiled it from the comfort of a non-win32 platform, using mingw. Binaries built with mingw should...
Posted in All Buzz Forum, Mar 31, 2006, 4:39 PM
Ever wanted to pipe a tail -f through HTTP? I made a quick hack in order to use the excellent rikaichan extension for Firefox in real-time IRC conversations: I was going to code a File::Tail but a quick look at the RAA pointed me to Florian Frank's file-tail, making the remaining code trivial: Read more...
Posted in All Buzz Forum, Mar 29, 2006, 6:39 PM
Using google (or any other search engine) to generate persistent URLs is one of those obvious ideas that make you wonder if you came to them on your own before being exposed. At any rate, I had never seen an implementation*1, so here's mine. But first of all, some examples of the persistent URLs created by the script shown below: my Ruby...
24 pages [ Previous 1 ... 16 17 18 19 20 21 22 23 24 Next ]
Advertisement