From: Stefano Crocco Date: 2008-09-18T16:00:56+09:00 Subject: Re: The mystery of File::append Alle Thursday 18 September 2008, Nit Khair ha scritto: > $ ri File::append > gives me: > > File::append( file, str ) > ------------------------------------------------------------------------ > Append to a file. > > CREDIT: George Moschovitis > > `$ri File` also shows me append as a class method. > > However, my html documentation does not give this (1.8.6). Trying to use > `File::append` in irb or ruby fails (no such method). Even google has no > entry for this class method. > > What mistake am I making ? It's part of the facets library. Unfortunately, ri doesn't show the name of the file where a method or class is defined or the library or gem it comes from. To use that method, since it seems you already have facets installed, you need to do this: require 'rubygems' #unless it's already defined in the RUBYOPT environment #variable require 'facets/file/write' File.append(file, str) I hope this helps Stefano