irb actually preserves ENV['COLUMNS']. If you try running that same  
command from within a proper ruby script, though, you'll find it  
returning nil.

- Jamis

On Jan 12, 2007, at 7:09 PM, Wayne E. Seguin wrote:

>
> This may be too simplistic but couldn't you simply get the value  
> from a
> simple system call?
>
> irb(main):001:0> `echo $COLUMNS`.strip.to_i
> => 136
>
>   ~Wayne
>
> Jamis Buck wrote:
>> Actually, looks like Ruby can't see the ENV["COLUMNS"] value (see
>> http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/211453).
>> For now, I'll just drop that part of the patch and hard-code 80,
>> until someone can come up with a platform-independent way of querying
>> the terminal size.
>>
>> - Jamis
>>
>
>
> >


--~--~---------~--~----~------------~-------~--~----~
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/capistrano
-~----------~----~----~----~------~----~------~--~---

Reply via email to