377646-379916 subjects 378100-378938

Convert HTML to Confluence Wiki
377847 [jeremy.barth] I'm converting data from a legacy system into a new RoR system.  The

attr_reader - general question
377850 [jcarter@le p] class ExternalBallistics
+ 377851 [jgabrielygal] This is not calling the method "c=3D", not that you have one, in any
+ 377852 [steve@st ve ] nope, if you 'puts calcluate' you should see 8. If you want to assign to c,

Where to start
377854 [tescatlipoca] a chance till now.
377859 [h3rald@h3 al] The easiest (and most pleasant to work with!) Ruby GUI toolkit is definitely=
377860 [steve@st ve ] +1 for Shoes. I am a bit biased, being on Team Shoes, though. ;)
377871 [h3rald@h3 al] I really can't wait until you can provide a proper gem. While Shoes is fine f=
377875 [ninja@sl ph ] +1
377880 [steve@st ve ] David, right now, they're 100% intertwined. That's the way that _why liked
377903 [ninja@sl ph ] Ok. The question is why he liked it, if you'll pardon the pun.
377963 [steve@st ve ] First of all, a disclaimer: I never met or talked to _why. So I can't really
377967 [ninja@sl ph ] That sounds like a problem for something like rawr. As far as I can tell, it's
377973 [steve@st ve ] Totally. Just explaining why things are the way that they are, and why they

ANN: Sequel 3.20.0 Released
377855 [code@je em e] Sequel is a lightweight database access toolkit for Ruby.
377885 [botpena@gm i] minor nit..
377958 [code@je em e] Jeremy

377861 [e-ken@ya de ] unsubscribe

Returning a column vector from a 2D array
377862 [jcarter@le p] I have a @data_array variable, which is a 2 dimensional array.  If I
+ 377876 [jgabrielygal] Can you show some code? Are you using a specific 2d array from a
+ 377878 [jcarter@le p] Hope this isn't too fragmentary and of no use
+ 377985 [jcarter@le p] Using Matrix.rb does not work in this application, because I have to

rvm upgrade gemset gone
377863 [pal@pa be gs] I did a rvm upgrade. I said yes to move the gemset. Now, after
+ 377867 [pal@pa be gs] Looks like they are deleted.
+ 377900 [pal@pa be gs] Never mind. I had to reinstall them. All ok now.

377864 [e-ken@ya de ] unsubscribe

377865 [e-ken@ya de ] unsubscribe    unsubscribe   unsubscribe 'unsubscribe'
377866 [jeremy@bo p.] ruby-talk-ctl@ruby-lang.org instead.  If that doesn't work for some

Search String and Delete Line Containing String
377868 [roberth@mo a] I am new to Ruby and am pulling my hair out on something that I know is
+ 377869 [roberth@mo a] I am new to Ruby and am pulling my hair out on something that I know is
+ 377872 [jeremy@bo p.] path='c:\ruby192\my_projects\IIS_Logs\ex11012607.log'
+ 377873 [b.candler@po] gsub! returns the whole line after the substitution has taken place, or
+ 377920 [shortcutter@] The simplest solution for this that I can think of is

TweetStream locations?
377870 [skins96@gm i] As I understand it, TweetStream has support for searching by locations.

remove array bracket
377882 [niezam54@ho ] [{"name"=>"Efficiency (Energy)",
+ 377883 [yongjiawei@g] Are these output to a txt file, or irb? Mind sharing your output
+ 377884 [jeremy@bo p.] How does your script produce that output in the first place?  I'm going
+ 377887 [niezam54@ho ] Actually i just want to remove the bracket (The very first and last
| 377888 [jeremy@bo p.] The variable tar is an array of hashes, and the first output you posted
+ 377889 [niezam54@ho ] class EnergyManagement < Environmental
| + 377890 [jeremy@bo p.] At this point I can't see where the problem is since none of this
| + 377892 [cmdjackryan@] What does the Environmental class look like?
+ 377893 [niezam54@ho ] class Environmental
| 377894 [jeremy@bo p.] Given the way you used this class within the EnergyManagement class,
| 377910 [shortcutter@] title
| 377933 [jeremy@bo p.] I think there is confusion here because of the way Nizam phrased the
+ 377901 [niezam54@ho ] Thanks Jeremy,
| 377932 [jeremy@bo p.] Check out Hash#merge.  Assuming you have an array of hashes in the
+ 377902 [niezam54@ho ] Btw there is a catch, {yyyyyy} hash is created based on a looping method
| 377935 [jeremy@bo p.] I'm not sure what you're saying here.  If you're saying you need some
+ 377992 [niezam54@ho ] I have already solved the problem by myself by manipulating bit of the
  377993 [jeremy@bo p.] What's important is that you fixed your problem and that you understand

What is the reason behind Array#zip's name?
377895 [darkintent@g] I'm just curious I know that Array#zip generates a new array from arguments
377896 [jeremy@bo p.] I think it's inherited from a similarly named function that carries out
377898 [darkintent@g] Haskell happened to be the second place I have seen this particular function

What is the difference between a Ruby array and a list in Haskell or Lisps?
377897 [darkintent@g] As the title asks what is the difference between a Ruby array and a list in
377904 [ninja@sl ph ] Ruby arrays are probably closest to C++ vectors or Java ArrayLists -- almost
377908 [shortcutter@] in
377909 [fxn@ha hr f.] FWIW, Common Lisp at least has also arrays.

[ANN] parslet 1.1 - a PEG parser library
377905 [eule@sp ce c] parslet is a Parsing Expression Grammar based[1] parser generator
378007 [ryand-ruby@z] library. Uff. Now that is out of our system, here goes what it really =

rjb - java vm error
377911 [nedumeritulc] in 'load': can't create Java VM (RuntimeError).
+ 377914 [dhruva.sagar] Make sure Java is in your PATH and your JAVA_HOME environment variable is
| 377916 [nedumeritulc] I have set JAVA_HOME but i get the same error
| 377953 [artonx@ya oo] I need more information about your envionment.
| 378036 [nedumeritulc] Microsoft Windows [Version 6.1.7600]
| 378041 [artonx@ya oo] Then please let me know the command line output of
| 378191 [nedumeritulc] Exception `LoadError' at C:/Ruby/lib/ruby/site_ruby/1.8/rubygems.rb:1113
| 378251 [artonx@ya oo] Sorry for late reply
+ 408179 [lists@ru y- ] I am getting the same error.  I'm running on Linux, and JAVA_HOME is set

Question about donation
377917 [max@do -t .i] Good afternoon!

cp_r is not working
377922 [eliranbz@gm ] I'm trying to build a program which copy from source folder to dest
377924 [shortcutter@] You need do prepend the path, e.g.
377944 [eliranbz@gm ] Thanks all, I figure it out, It tried to copy the folder itself to
378031 [xavier.nayra] Dir.foreach(path) do |file|

Is there a Date.now equivalent of Time.now/new?
377925 [mfcoder-ap@y] On Ruby 1.8.7 and 1.9 somewhere (some ARM NAS device).
+ 377926 [rahegge@gm i] Date.today.to_s
+ 377927 [peterhickman] You could just use Date.today
  377929 [mfcoder-ap@y] Thanks.  I guess my point was (probably) that Date.now is more intuitive
  377940 [botpena@gm i] not an anglois expert here, but

Soliciting some help with inject method
377934 [edmond.kacha] Rubysters,
+ 377936 [jeremy@bo p.] array.inject({}) do |result, (key, value)|
+ 377937 [mentionuse@g] You can do this without an inject, with a simple iteration and a bit of ||=
+ 377938 [wagner.andre] hash = array.inject({}) do |result, array|
| 377942 [edmond.kacha] 2011/2/2 Andrew Wagner <wagner.andrew@gmail.com>
| 377943 [edmond.kacha] e))
| + 377948 [jgabrielygal] You'd be surprised :-). If I didn't do anything wrong (I usually make
| + 377949 [botpena@gm i] contribution,
+ 377941 [jgabrielygal] fails

Editing a text file and then replacing existing file
377945 [roberth@mo a] I have a script that I use to find text in a file and then delete the
377951 [jeremy@bo p.] First of all, let's simplify this code by using a single regexp that
377957 [shortcutter@] Just an additional perspective: for things like this it's probably

General conceptual question
377946 [jmdetloff@gm] I'm trying to have a script that runs at all times, pulling tasks from a
377947 [h3rald@h3 al] Distributed Programming with Ruby --
378034 [jmdetloff@gm] Thanks, that was just the guidance I needed to get me started in the

Amazing behavior of include module
377952 [pavel.strnad] ...
+ 377999 [wagner.andre] This is really quite odd to me. Especially since AAA::BBB.constants returns
| 378001 [mentionuse@g] Including AAA at the top level, as in line 7, acts the same as including it
| 378013 [wagner.andre] This explanation makes sense, and certainly fits the facts. But why is doing
| + 378015 [adgar@ca bo ] I'm actually working on a static analysis tool that came up against the =
| + 378035 [shortcutter@] it
+ 378008 [josh.cheek@g] module A

Bug in system()?
377954 [anthony@ov r] I've just hit a problem where the system() method to call an external program failed in a fairly unpredictable way, and I couldn't get any clues from within ruby to diagnose the problem, so I ended up debugging process.c to work out what the problem was.
378042 [shortcutter@] gram failed in a fairly unpredictable way, and I couldn't get any clues fro=

Gem win32-eventlog v0.5.2 on Ruby 1.9.1
377956 [lmayorga1980] 1.Requirement:  Read the latest lines of the Windows Application Event
377959 [luislavena@g] Please try Ruby 1.9.2-p136.
+ 377960 [lmayorga1980] I will try this new version.
| 377962 [lmayorga1980] I tried the new version Ruby 1.9.2, installing the win32-eventlog gem
| 377966 [luislavena@g] ne
| 377968 [lmayorga1980] You mean adding at the top of the script the following line.
+ 378003 [lmayorga1980] SOLUTION!!!!

problems installing Ruby Unit-0.5.6
377964 [bott2k7@ya o] To Whom It May Concern-

Need "=" to look like a strint
377965 [roberth@mo a] I have the following variable. Ruby looks at the = sign as a regex
+ 377975 [hassan.schro] ruby-1.8.7-p302 > pattern =3D %r{=3D}
+ 377978 [jeremy@bo p.] You have a typo in your code sample here, and the message you see as a
  378012 [echristopher] I think he meant to use =3D~ instead.
  378014 [jeremy@bo p.] That's a possibility, but take a look at the conversations in recent

Net::Telnet question
377970 [nick.hill.03] I am trying to use Net::Telnet to telnet to a website  to check network
378055 [b.candler@po] That's the wrong tool for the job. If you just want to test that the

Help with outfile.write(line) unless line =~ search_text
377972 [roberth@mo a] Rather than having the output write the line unless it equals
377976 [pat.eyler@gm] try if instead of unless
377981 [jeremy@bo p.] Using if instead of unless is definitely clearer here, but you can also

master select list changes contents of slave select lists
377974 [danthom1000@] I have one drop-down list (call it master) that needs to change the

Problem with return from method
377982 [byrnejb@ha t] .  .  .
377984 [byrnejb@ha t] Found the error.  I was not explicitly returning the remapped hash as a

Combining two file write commands
377986 [roberth@mo a] First, let me think everyone for the wonderful advice, especially,
377987 [jeremy@bo p.] Each of these writes is executed under separate conditions, so they need

sql IN (and other special operators) and bind parameters
377994 [iainspeed@gm] Does anyone know if any of the Ruby gems for SQL implement support for =

Converting date format (CSV to yaml)
377996 [niezam54@ho ] Anyone know how to convert date format of .csv to . yaml?
+ 378002 [anurag08priy] cdate = "12/1/2011"
+ 378009 [brabuhr@gm i] Another option could be to parse the String into a Date that is then
+ 378016 [niezam54@ho ] cdate = "2011-01-12"
| 378017 [jeremy@bo p.] The pp method is adding the quotation marks when printing the string.
+ 378018 [niezam54@ho ] But when i tried transferring the ydate into my yaml structure, it still
| 378020 [jeremy@bo p.] It's because you actually have a String rather than a Date object.  Try
+ 378021 [niezam54@ho ] I used both method. Both of them return an error
+ 378024 [botpena@gm i] when csv reads the data, it's still a string. you may want to convert
+ 378026 [niezam54@ho ] problem solved. thanks guys!!!

Help needed for Ruby & Watir Configuration
378000 [successware@] Recently I installed following versions
378382 [pmckibbin@gm] require 'watir'

Win32 Service Logon Failure
378022 [ashish_deepa] I desperately need help with this as I can't understand why it is
378348 [ashish_deepa] Found the solution.

For Loop with Steps?
378023 [thescholar@h] And I already have a noob question.
+ 378025 [adgar@ca bo ] ...
+ 378027 [botpena@gm i] try this,
| 378033 [shortcutter@] There is also Fixnum#step
+ 378028 [thescholar@h] Thank you very much!

wolf 0.1.0 - Initial release
378029 [gabriel.horn] Announcing an initial release of wolf, https://github.com/cldwalker/wolf,

loop, insdide do loop. do twice?
378030 [i8igmac@ai .] mply = 0
378032 [shortcutter@] You can use #times for iteration.

[ANN] noe 1.3.0 Released
378037 [blambeau@gm ] noe version 1.3.0 has been released!

Re: noe 1.3.0 Released
378039 [jrmair@gm il] What are the advantages of noe over https://github.com/twp/bones
378040 [blambeau@gm ] * I've tried to summarize the differences in two sections at

Class Instanciation in loop
378045 [alizee.penel] I am a beginner in Ruby and i am faced to a problem I do not understand.
+ 378076 [alizee.penel] Nobody wants to help me ?
| 378080 [botpena@gm i] maybe because you did not provide all the relevant data/codes/classes/
+ 378078 [stefano.croc] nd.

Setter method for Hash value
378046 [rolfhsp@gm i] I guess there is a simple solution to this, but right now, I can't come up
+ 378047 [botpena@gm i] ct
| 378050 [chris.hulan@] You might want to have a look at http://www.ruby-doc.org/stdlib/libdoc/forwardable/rdoc/index.html
+ 378048 [Carey.Nation] Try calling it props=3D for the method name itself.
+ 378049 [zhangsu@li e] class MyClass
+ 378051 [rolfhsp@gm i] I see I have forgotten something when extracting code to a more generic
+ 378052 [b.candler@po] def []=(key,value)
  378056 [rolfhsp@gm i] line)
  + 378073 [botpena@gm i] objects receive methods wc return objects, wc in turn can receive
  | 378074 [botpena@gm i] sorry, ignore the previous unclear post..
  | 378082 [rolfhsp@gm i] Thanks for the input, botp.
  + 378081 [b.candler@po] Then the 'props' object which you return needs methods [] and []=
    378094 [rolfhsp@gm i] Hei Brian
    + 378095 [jgabrielygal] class MyClass
    | 378098 [rolfhsp@gm i] It does seem to be working. At least the example "requirements" that I
    | 378105 [jgabrielygal] 1.- Calls on the instance of MyClass: props and props=
    | + 378138 [rolfhsp@gm i] 2011/2/4 Jes=FAs Gabriel y Gal=E1n <jgabrielygalan@gmail.com>
    | + 378180 [rolfhsp@gm i] 2011/2/4 Jes=FAs Gabriel y Gal=E1n <jgabrielygalan@gmail.com>
    |   378196 [jgabrielygal] ore
    + 378097 [b.candler@po] Then simply return an object with those characteristics. This is Ruby,

Need a method to generate cubic spline control points
378058 [rich@ga da f] My name is Rich Price and I am looking for some help from a
378066 [wagner.andre] So this math is a little over my head, but I can read the ruby and c# pretty

Search directory for containing specified string
378060 [roberth@mo a] I am trying to search a directory for all files that contain a specific
+ 378064 [jeremy@bo p.] It's able to filter files based on regular expressions as well as
+ 378071 [angel_steel@] check to make sure MQ4 are text files. I suspect its an executable file
+ 378084 [shortcutter@] Do you want to look for literal parentheses?  Otherwise this empty

Parsing Log records with regular expressions
378061 [iamkrisko@gm] I have a log file which is text based which has records in two formats
378083 [shortcutter@] Question is: why do you want to do that?  Line based parsing is simple
378107 [iamkrisko@gm] Thanks for the prompt response. Apprecite your taking the time to

windows: show activex
378065 [rogerpack200] or its equivalent for WIN32OLE ?
378092 [koulikoff@gm] I'm afraid, you will have to write it yourself ;-)

Strange "ruby -r debug t.rb" for PickAxe ver. 2's Fibonacci example
378067 [RichardDummy] Following are two examples of using ruby-debug on PickAxe ver. 2
378069 [rocky.bernst] The Ruby program debug.rb which comes with Ruby 1.x is what you get when
378093 [RichardDummy] ithub.com/rocky/rb-trepanningandhttp://github.com/rbx-trepanning) I've trie=

[ANN] kgio 2.2.0 - kinder, gentler I/O for the Internets
378072 [normalperson] kgio provides non-blocking I/O methods for Ruby without raising

Re: kgio 2.2.0 - kinder, gentler I/O for the Internets
378075 [sunaku@gm il] In case anyone is new to programming: the above is in ROT13.

problem with inheritance
378077 [lwrncmaina@g] class Input_Agent
+ 378079 [b.candler@po] In this code you are reading these values into local variables, which
+ 378091 [lwrncmaina@g] Thanks Brian. I declared the matrices in Solution_Agent in class

require 'kwalify' fails
378085 [jean-christo] I need to validate a YAML schema. I have found the Kwalify gem, but then
378125 [Ruby@Go gl M] "fails" is not exactly a descriptive error message.

Major update for R2CORBA available
378086 [mcorino@re e] Remedy IT is pleased to announce the release of version 1.0 of the Ruby

Arrays and defs
378087 [jens.finnas@] I've now run in to a problem I can't get my head around.
+ 378088 [wagner.andre] The problem here is that whenever you type "def", you start a new scope. And
| 378090 [masap.hat@gm] My recommends are
+ 378089 [jens.finnas@] Cheers. Thanks for all the advice. I have to admit that I'm not very
+ 378099 [botpena@gm i] ^^^^^ lose this. not needed since you created list below
  378114 [b.candler@po] Good idea here.