[#1649] Re: New Ruby projects — Yukihiro Matsumoto <matz@...>
The following message is a courtesy copy of an article
[#1672] Re: Ruby 1.4 stable manual bug? — Yukihiro Matsumoto <matz@...>
The following message is a courtesy copy of an article
[#1673] Re: Possible problem with ext/socket in 1.5.2 — itojun@...
[#1694] Conventions for our Ruby book — Dave Thomas <Dave@...>
[#1715] Install postgresql support — Ikhlasul Amal <amal@...>
Hi all,
Hi,
[#1786] Is this a bug? — Clemens Hintze <clemens.hintze@...>
(mailed & posted)
[#1814] Objects nested sometimes. — Hugh Sasse Staff Elec Eng <hgs@...>
I am attemptiong to write a package which consists of a workspace
[#1816] Ruby 1.5.3 under Tru64 (Alpha)? — Clemens Hintze <clemens.hintze@...>
Hi all,
Hi,
Yukihiro Matsumoto writes:
Hi,
Hi,
[#1834] enum examples? — Hugh Sasse Staff Elec Eng <hgs@...>
Has anyone any examplse of using the Enumerable module? I've had a
[#1844] Minor irritation, can't figure out how to patch it though! — Hugh Sasse Staff Elec Eng <hgs@...>
I was considering how difficult it would be to patch Ruby to accept
[#1889] [ruby-1.5.3] require / SAFE — ts <decoux@...>
[#1896] Ruby Syntax similar to other languages? — "David Douthitt" <DDouthitt@...>
From: Yukihiro Matsumoto <matz@netlab.co.jp>
[#1900] Enumerations and all that. — Hugh Sasse Staff Elec Eng <hgs@...>
Thank you to the people who responded to my questions about Enumerated
Hugh Sasse Staff Elec Eng <hgs@dmu.ac.uk> writes:
On 16 Mar 2000, Dave Thomas wrote:
[#1929] Re: Class Variables — "David Douthitt" <DDouthitt@...>
| "David Douthitt" <DDouthitt@cuna.com> writes:
[#1942] no Fixnum#new ? — Quinn Dunkan <quinn@...>
Ok, I can add methods to a built-in class well enough (yes I know about succ,
[#1989] English Ruby/Gtk Tutorial? — schneik@...
Hi,
[#2022] rb_global_entry — ts <decoux@...>
[#2036] Anonymous and Singleton Classes — B_DAVISON <Bob.Davison@...>
I am a Ruby newbie and having some problems getting my mind around certain
[#2069] Ruby/GTK+ question about imlib --> gdk-pixbug — schneik@...
[#2073] Re: eval.rb fails — "Dat Nguyen" <thucdat@...>
The doc is fine, this happens only if you try to execute 'until' block
On Wed, 22 Mar 2000, Dat Nguyen wrote:
[#2084] Scope violated by import via 'require'? — Clemens Hintze <c.hintze@...>
Hi,
[#2104] ARGF or $< — Hugh Sasse Staff Elec Eng <hgs@...>
Has anyone any examples of how to use ARGF or $< as I cannot find much
Hi.
[#2165] Ruby strict mode and stand-alone executables. — "Conrad Schneiker" <schneiker@...>
Some people want Ruby to have a strict compile mode.
[#2203] Re: parse bug in 1.5 — schneik@...
[#2212] Re: Ruby/Glade usage questions. — ts <decoux@...>
>>>>> "m" == mrilu <mrilu@ale.cx> writes:
[#2241] setter() for local variables — ts <decoux@...>
[#2256] Multiple assignment of pattern match results. — schneik@...
[#2267] Re: Ruby and Eiffel — h.fulton@...
[#2309] Question about attribute writers — Dave Thomas <Dave@...>
Clemens Hintze <c.hintze@gmx.net> writes:
[ruby-talk:01968] Re: BUG???
| Hi,
|
| In message "[ruby-talk:01936] BUG???"
| on 00/03/16, "David Douthitt" <DDouthitt@cuna.com> writes:
|
| |# ./others.rb sys1 sys2 sys3 sys4 sys5 sys6 | less
| |./others.rb:29: [BUG] obj_free() called for broken object
| | Mar 12 17:19:36 172.16.17.31 printer: offline or intervention needed
| | Mar 12 17:19:36 172.16.17.31 printer: paper out
| | Mar 12 17:20:10 172.16.17.31 printer: error cleared
| | Mar 12 18:31:10 172.16.17.31 printer: toner/ink low
| |Abort
| |#
|
| Sorry, I can't reproduce your problem.
| Could you show me your `ruby -v'?
I'll do better than that :-)
(But "ruby -v" is in the middle...)
[...cut here...]
# ./others.rb sys1 sys2 sys3 sys4
Mar 12 04:03:1 sys5 Mar 12 03:56:30
Mar 12 04:33:0 sys5 Mar 12 04:26:27
Mar 12 05:03:1 sys5 Mar 12 04:56:32
Mar 12 05:33:0 sys5 Mar 12 05:26:29
Mar 12 06:03:1 sys5 Mar 12 05:56:34
Mar 12 06:33:0 sys5 Mar 12 06:26:29
Mar 12 07:03:1 sys5 Mar 12 06:56:34
Mar 12 07:33:1 sys5 Mar 12 07:26:31
Mar 12 08:03:1 sys5 Mar 12 07:56:36
Mar 12 08:33:1 sys5 Mar 12 08:26:31
Mar 12 09:03:1 sys5 Mar 12 08:56:37
Mar 12 09:33:1 sys5 Mar 12 09:26:33
Mar 12 10:03:1 sys5 Mar 12 09:56:38
Mar 12 10:33:1 sys5 Mar 12 10:26:35
Mar 12 11:03:2 sys5 Mar 12 10:56:40
Mar 12 11:33:1 sys5 Mar 12 11:26:35
Mar 12 12:03:2 sys5 Mar 12 11:56:40
Mar 12 12:33:1 sys5 Mar 12 12:26:37
Mar 12 13:03:2 sys5 Mar 12 12:56:42
鬯/others.rb:20:in `systemName': Interrupt
from ./others.rb:27
from ./others.rb:24:in `each'
from ./others.rb:24
# ./others.rb sys1 sys2 sys3 sys4 sys5 sys6
Mar 12 17:19:36 172.16.17.31 printer: offline or intervention needed
Mar 12 17:19:36 172.16.17.31 printer: paper out
Mar 12 17:20:10 172.16.17.31 printer: error cleared
Mar 12 18:31:10 172.16.17.31 printer: toner/ink low
./others.rb:29: [BUG] obj_free() called for broken object
Abort
# uname -a
Linux sysadm.cuna.com 2.2.9-27mdk #1 Mon Jun 14 16:44:05 CEST 1999 i586 unknown
# rpm -qi ruby
Name : ruby Relocations: /usr
Version : 1.4.3 Vendor: MandrakeSoft
Release : 3mdk Build Date: Tue Feb 15 19:47:28 2000
Install date: Thu Mar 2 17:00:27 2000 Build Host: kenobi.mandrakesoft.com
Group : Development/Languages Source RPM: ruby-1.4.3-3mdk.src.rpm
Size : 2313282 License: GPL
Packager : Atsushi Yamagata <yamagata@plathome.co.jp>
URL : http://www.netlab.co.jp/ruby/jp/
Summary : Object Oriented Script Language
Description :
Ruby is the interpreted scripting language for quick and
easy object-oriented programming. It has many features to
process text files and to do system management tasks (as in
Perl). It is simple, straight-forward, and extensible.
# ruby -v
ruby 1.4.3 (1999-12-08) [i586-linux-gnu]
# cat others.rb
#!/usr/bin/ruby
# Interesting problem reached here...
#
# ARGV is [ "arg1", "arg2", "arg3" ]
# results from a scan are [ [ "str1" ] ]
#
# Thus, ARGV.each is "arg1" ... "arg2" ... "arg3" ...
# scanXX.each is [ "str1" ] ... [ "str2 ] ...
#
# Thus ARGV[0] is "arg1" ; scanXX[0] is [ "str1" ] ;
# and scanXX[0][0] is "str1"
#
# This explains a lot.
systems = Array.new
class String
def systemName
self.scan("^... .. ..:..:.. ([^ ]*)")
end
end
File.open("/var/log/messages").each { |line|
line.chomp!
# sys = line.scan("^... .. ..:..:.. ([^ ]*)")
sys = line.systemName
systems = systems | sys
if not ARGV.include?(sys[0][0])
print(" ", line, "\n")
end
}
# (systems.sort!).each { |sys|
# print(" ", sys, "\n")
# }
#
[...snip...]
I thought that first bit was interesting - a run that was interrupted
with control-C (SIGINT) had no such "Abort" or "[BUG]" message.
I might note that I am also working in ruby under HP-UX ... so don't
always assume I'm using Linux :-)
Is ruby available for Unixware as a Unixware package? I found
an RPM for Linux (obviously) and a Software Depot for HP-UX.
Is there a package for FreeBSD? (just curious)