<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel>
    <title>Ruby Forum RSS Feed</title>
    <link>http://www.programmersheaven.com/</link>
    <description>Contains the latest threads from the 'Ruby' forum at Programmer's Heaven, excluding replies.</description>
    <language>en</language>
    <copyright>Copyright 2008 Programmers Heaven</copyright>
    <pubDate>Thu, 24 Jul 2008 22:24:51 -0700</pubDate>
    <lastBuildDate>Thu, 24 Jul 2008 22:24:51 -0700</lastBuildDate>
    <generator>Argotic Syndication Framework 2007.3.0.1, http://www.codeplex.com/Argotic</generator>
    <docs>http://www.rssboard.org/rss-specification</docs>
    <ttl>360</ttl>
    <image>
      <url>http://www.programmersheaven.com/images/ph.gif</url>
      <title>Programmers Heaven</title>
      <link>http://www.programmersheaven.com/</link>
      <width>88</width>
      <height>31</height>
    </image>
    <item>
      <title>RoR Development Team</title>
      <link>http://www.programmersheaven.com/mb/ruby/373468/373468/ReadMessage.aspx</link>
      <description>We represent an established team of three Ruby on Rails developers who are available immediately for projects large or small.&lt;br /&gt;
&lt;br /&gt;
Technical Experience:&lt;br /&gt;
* Each developer was selected from a large pool of candidates passing multiple rounds of written and oral technical interviews&lt;br /&gt;
* Experienced in rich AJAX Web 2.0 applications using JavaScript and Rails helpers to interface Prototype and Script.aculo.us libraries.&lt;br /&gt;
* Deep knowledge of Rails 1.2 &amp;amp; Rails 2.0 frameworks and REST::NET web services, attachmentfu, Rmagick, Spry framework etc&lt;br /&gt;
* Deployment expertise in Windows and Linux to setup architectures with mongrel clusters using either apache or nginx&lt;br /&gt;
&lt;br /&gt;
Recent projects the team has completed:&lt;br /&gt;
* Custom-built ERP system for a manufacturing company (7000+ programming hours)&lt;br /&gt;
* Custom-built administrable online content-sharing application (1000+ programming hours)&lt;br /&gt;
* Entertainment portal, allowing users to search for and view online multimedia from various sources (500+ programming hours)&lt;br /&gt;
&lt;br /&gt;
The team is in South America, so the rates are substantially below typical US standards while the developers are vertically below US time zones, making communication much easier than with India.  They prefer to work with an Agile development methodology that includes frequent releases and communication.  The team is fluent in Spanish and has excellent written English with good spoken English.&lt;br /&gt;
&lt;br /&gt;
If desired, DreamStaffing can also supplement this team with a fluent bi-lingual project manager, HTML/CSS developers, user interface designers, or any other skill sets that are needed for a project.&lt;br /&gt;
&lt;br /&gt;
Please contact us at ROR-team@dreamstaffing.com  for more information.&lt;br /&gt;
&lt;br /&gt;</description>
      <pubDate>Thu, 17 Jul 2008 23:07:54 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>Need help with a script</title>
      <link>http://www.programmersheaven.com/mb/ruby/372660/372660/ReadMessage.aspx</link>
      <description>When i run this code (through NETBEANS - with ruby addon) it does not function correctly.&lt;br /&gt;
It doesn't login correctly and I'm not sure whats wrong.&lt;br /&gt;
Im am still in the process of learning ruby, and any help would be greatly appreciated.&lt;br /&gt;
&lt;hr /&gt;&lt;br /&gt;
#!/usr/bin/ruby&lt;br /&gt;
require 'open-uri'&lt;br /&gt;
&lt;br /&gt;
#E-Mail and Password... replace /'s with %2f&lt;br /&gt;
email = "hotmail@hotmail.com"&lt;br /&gt;
password = "****************"&lt;br /&gt;
&lt;br /&gt;
#Whatever the file name is that you're using... Mining is view.fcgi (if I remember, chatbox is comm.fcgi etc.)&lt;br /&gt;
file_name = "view.fcgi"&lt;br /&gt;
&lt;br /&gt;
#What it says in the address bar besides the email and password. Make sure a &amp;amp; precedes every variable&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;do=2&amp;amp;lvl=13"&lt;br /&gt;
&lt;br /&gt;
#Don't change this...&lt;br /&gt;
referer = "http://a3.alienaa.com/cgi-bin/#{file_name}"&lt;br /&gt;
url = "http://a3.alienaa.com/cgi-bin/#{file_name}?&amp;amp;email=#{email}&amp;amp;pass=#{password}"&lt;br /&gt;
user_agent = "Mozilla/5.0 (compatible; MSIE 6.0; Windows NT 5.1)"&lt;br /&gt;
&lt;br /&gt;
#Amount of veins to mine&lt;br /&gt;
veins = -1&lt;br /&gt;
to_mine = 200&lt;br /&gt;
&lt;br /&gt;
#Final URL to use in open()&lt;br /&gt;
goto = "#{url}#{uri}"&lt;br /&gt;
&lt;br /&gt;
#Previous direction that was gone. options are: n (north), e (east), s (south), w (west)&lt;br /&gt;
prev_dir = ""&lt;br /&gt;
&lt;br /&gt;
#Method for when it gets stuck with only one option (going east, only option west, so it can't move)&lt;br /&gt;
def stuck line, prev_dir&lt;br /&gt;
if (prev_dir == "e" || prev_dir == "w")&lt;br /&gt;
if (!(/&amp;amp;go=s&amp;gt;/ =~ line) &amp;amp;&amp;amp; (!(/&amp;amp;go=n&amp;gt;/ =~ line)))&lt;br /&gt;
return true&lt;br /&gt;
end&lt;br /&gt;
elsif (prev_dir == "s" || prev_dir == "n")&lt;br /&gt;
if (!(/&amp;amp;go=w&amp;gt;/ =~ line) &amp;amp;&amp;amp; (!(/&amp;amp;go=e&amp;gt;/ =~ line)))&lt;br /&gt;
return true&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
#method for finding out which to map to&lt;br /&gt;
def prev dir&lt;br /&gt;
if (dir == "e")&lt;br /&gt;
return "w"&lt;br /&gt;
elsif (dir == "w")&lt;br /&gt;
return "e"&lt;br /&gt;
elsif (dir == "s")&lt;br /&gt;
return "n"&lt;br /&gt;
elsif (dir == "n")&lt;br /&gt;
return "s"&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
#timer vars, to change up the directions (so it doesn't get into a pattern)&lt;br /&gt;
set_arr = ['e','s','w','n']&lt;br /&gt;
rand_arr = []&lt;br /&gt;
trail = []&lt;br /&gt;
trail_moves = 0&lt;br /&gt;
moves = 0&lt;br /&gt;
&lt;br /&gt;
def track_back prev_dir&lt;br /&gt;
case prev_dir&lt;br /&gt;
when "e"&lt;br /&gt;
return "w"&lt;br /&gt;
when "w"&lt;br /&gt;
return "e"&lt;br /&gt;
when "n"&lt;br /&gt;
return "s"&lt;br /&gt;
when "s"&lt;br /&gt;
return "n"&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
while (veins &amp;lt; to_mine)&lt;br /&gt;
#1 second sleep for one connection a second&lt;br /&gt;
sleep(0.10);&lt;br /&gt;
goto = "#{url}#{uri}"&lt;br /&gt;
open( goto, "Referer"=&amp;gt;referer, "User-Agent"=&amp;gt;user_agent ) do |site|&lt;br /&gt;
line = site.read&lt;br /&gt;
if (/&amp;amp;step=pit&amp;amp;mine=1/ =~ line)&lt;br /&gt;
if (/&amp;amp;step=pit&amp;amp;mine=1&amp;amp;shovel=1/ =~ line)&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;mine=1&amp;amp;shovel=1"&lt;br /&gt;
puts "Shoveled for extra ore! Sweet!"&lt;br /&gt;
#veins += 1&lt;br /&gt;
else&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;mine=1"&lt;br /&gt;
puts "Mined"&lt;br /&gt;
#veins += 1&lt;br /&gt;
end&lt;br /&gt;
break&lt;br /&gt;
elsif ((/&amp;amp;leave=1/ =~ line || /&amp;amp;next=1/ =~ line) &amp;amp;&amp;amp; (prev_dir == "" || prev_dir == "leave"))&lt;br /&gt;
if (/&amp;amp;leave=1/ =~ line)&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;leave=1"&lt;br /&gt;
prev_dir = "leave"&lt;br /&gt;
elsif (/&amp;amp;next=1/ =~ line)&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;next=1"&lt;br /&gt;
prev_dir = "next"&lt;br /&gt;
trail = []&lt;br /&gt;
trail_moves = 0&lt;br /&gt;
end&lt;br /&gt;
break&lt;br /&gt;
else&lt;br /&gt;
if (prev_dir == "leave") #Check to see if on the wrong level&lt;br /&gt;
break&lt;br /&gt;
end&lt;br /&gt;
puts prev_dir if (trail_moves &amp;lt;= 150)&lt;br /&gt;
moves += 1&lt;br /&gt;
if (moves &amp;gt; 40 )&lt;br /&gt;
while (!(set_arr.empty?))&lt;br /&gt;
rand_arr.push(set_arr.delete_at(rand(set_arr.size)
))&lt;br /&gt;
end&lt;br /&gt;
set_arr = rand_arr&lt;br /&gt;
rand_arr = []&lt;br /&gt;
puts "Directions Randomized!"&lt;br /&gt;
moves = 0&lt;br /&gt;
end&lt;br /&gt;
if (trail_moves &amp;gt; 50) #Maximum amount of steps, traces back&lt;br /&gt;
trace_pop = trail.pop&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=#{trace_pop}"&lt;br /&gt;
print "trace"&lt;br /&gt;
puts trace_pop&lt;br /&gt;
if (trail.empty? or /&amp;amp;do=1&amp;amp;lvl=13/ =~ line)&lt;br /&gt;
if (/&amp;amp;do=1&amp;amp;lvl=13/ =~ line)&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;do=2&amp;amp;lvl=13"&lt;br /&gt;
end&lt;br /&gt;
trail_moves = 0&lt;br /&gt;
trail = []&lt;br /&gt;
prev_dir = ""&lt;br /&gt;
end&lt;br /&gt;
moves = 0&lt;br /&gt;
break&lt;br /&gt;
end&lt;br /&gt;
if (/&amp;amp;do=1&amp;amp;lvl=13/ =~ line) #Check to see if you died during the pit&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;do=2&amp;amp;lvl=13"&lt;br /&gt;
prev_dir = ""&lt;br /&gt;
puts "Dead, restarting"&lt;br /&gt;
trail_moves = 0&lt;br /&gt;
trail = []&lt;br /&gt;
moves = 0&lt;br /&gt;
break&lt;br /&gt;
end&lt;br /&gt;
if (prev_dir == "" || prev_dir == "next")&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=s"&lt;br /&gt;
prev_dir = "s"&lt;br /&gt;
trail.push("n")&lt;br /&gt;
trail_moves += 1&lt;br /&gt;
break&lt;br /&gt;
elsif (/&amp;amp;go=#{prev_dir}&amp;gt;/ =~ line)&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=#{prev_dir}"&lt;br /&gt;
trail.push(track_back(prev_dir))&lt;br /&gt;
trail_moves += 1&lt;br /&gt;
break&lt;br /&gt;
elsif ((/&amp;amp;go=#{set_arr[0]}&amp;gt;/ =~ line) &amp;amp;&amp;amp; (prev_dir != prev(set_arr[0]) || stuck(line, prev_dir)))&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=#{set_arr[0]}"&lt;br /&gt;
prev_dir = "#{set_arr[0]}"&lt;br /&gt;
trail.push(track_back(prev_dir))&lt;br /&gt;
trail_moves += 1&lt;br /&gt;
break&lt;br /&gt;
elsif ((/&amp;amp;go=#{set_arr[1]}&amp;gt;/ =~ line) &amp;amp;&amp;amp; (prev_dir != prev(set_arr[1]) || stuck(line, prev_dir)))&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=#{set_arr[1]}"&lt;br /&gt;
prev_dir = "#{set_arr[1]}"&lt;br /&gt;
trail.push(track_back(prev_dir))&lt;br /&gt;
trail_moves += 1&lt;br /&gt;
break&lt;br /&gt;
elsif ((/&amp;amp;go=#{set_arr[2]}&amp;gt;/ =~ line) &amp;amp;&amp;amp; (prev_dir != prev(set_arr[2]) || stuck(line, prev_dir)))&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=#{set_arr[2]}"&lt;br /&gt;
prev_dir = "#{set_arr[2]}"&lt;br /&gt;
trail.push(track_back(prev_dir))&lt;br /&gt;
trail_moves += 1&lt;br /&gt;
break&lt;br /&gt;
elsif ((/&amp;amp;go=#{set_arr[3]}&amp;gt;/ =~ line) &amp;amp;&amp;amp; (prev_dir != prev(set_arr[3]) || stuck(line, prev_dir)))&lt;br /&gt;
uri = "&amp;amp;step=pit&amp;amp;go=#{set_arr[3]}"&lt;br /&gt;
prev_dir = "#{set_arr[3]}"&lt;br /&gt;
trail.push(track_back(prev_dir))&lt;br /&gt;
trail_moves += 1&lt;br /&gt;
break&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
&lt;hr /&gt;</description>
      <pubDate>Sun, 15 Jun 2008 13:33:26 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>New and with a problem.</title>
      <link>http://www.programmersheaven.com/mb/ruby/372544/372544/ReadMessage.aspx</link>
      <description>Hi, all &lt;br /&gt;
I've just entered into the world of programming and, I guess I chose ruby.&lt;br /&gt;
I'm trying to make this work but it doesn't seem to wan't to&lt;br /&gt;
I don't know why it shows both ifs&lt;br /&gt;
If some one could help, I'd be really appreciative!&lt;br /&gt;
&lt;br /&gt;
puts 'Speak up Sonny I can\'t hear you.'&lt;br /&gt;
talk = gets.chomp&lt;br /&gt;
if talk == talk.capitalize or talk.downcase &lt;br /&gt;
  then puts 'What? Sonny speak louder! Like THIS.'&lt;br /&gt;
if talk == talk.upcase &lt;br /&gt;
  then puts 'no not since'&lt;br /&gt;
end&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;</description>
      <pubDate>Mon, 09 Jun 2008 16:41:41 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>what is printed by this function?</title>
      <link>http://www.programmersheaven.com/mb/ruby/370156/370156/ReadMessage.aspx</link>
      <description>Hey everyone.. i never used Ruby before ... so trying to learn more about it's techniques...&lt;br /&gt;
can someone please tell me what will be the output of the following program segment assuming that the &lt;strong&gt;puts&lt;/strong&gt; function prints its arguament on standard output followed by a newline.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="sourcecode"&gt;
      def h(k)
        k.call
        puts "in h"
      end

      def g(k)
        h(k)
        puts "in g"
      end

      def f()
        callcc {|cc|g(cc)}
        puts "in f"
      end

      f
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
thank you&lt;br /&gt;</description>
      <pubDate>Sat, 08 Mar 2008 18:09:26 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>Ruby vs. C++</title>
      <link>http://www.programmersheaven.com/mb/ruby/366596/366596/ReadMessage.aspx</link>
      <description>I have just posted on my blog the reasons why I think &lt;a href="http://outofthetriangle.wordpress.com/2007/10/18/is-c-the-only-real-language/"&gt;C++ is the one true programming language&lt;/a&gt; (I am being slightly tongue in cheek here). I used 10 questions to compare it to other languages. Unfortunately I have not been able to compare it to Ruby as I don’t have any significant experience of Ruby development. Would anyone be willing to score Ruby for me?&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</description>
      <pubDate>Thu, 18 Oct 2007 11:32:40 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>Come and join my forum!!!</title>
      <link>http://www.programmersheaven.com/mb/ruby/363787/363787/ReadMessage.aspx</link>
      <description>Come and join my forum!!!&lt;br /&gt;
&lt;br /&gt;
Many video and MP3 for you to download!!!&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://forums.boajjang.com"&gt;http://forums.boajjang.com&lt;/a&gt;&lt;br /&gt;
&lt;a href="http://www.boa-planet.net"&gt;http://www.boa-planet.net&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Please support my forum by uploading all your video and mp3 too!!! &lt;br /&gt;
Thank you!!!&lt;br /&gt;
&lt;br /&gt;</description>
      <pubDate>Wed, 25 Jul 2007 17:16:02 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>PayPal - SDK for Ruby</title>
      <link>http://www.programmersheaven.com/mb/ruby/363138/363138/ReadMessage.aspx</link>
      <description>Hello,&lt;br /&gt;
&lt;br /&gt;
Does PayPal have SDK for Ruby?&lt;br /&gt;
&lt;br /&gt;
Thanks,&lt;br /&gt;
&lt;br /&gt;
Tom&lt;br /&gt;</description>
      <pubDate>Thu, 12 Jul 2007 12:49:49 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>An Introduction to Web Development Using the Ruby on Rails Framework</title>
      <link>http://www.programmersheaven.com/mb/ruby/357778/357778/ReadMessage.aspx</link>
      <description>This article presents the basic concepts used by the popular Ruby on Rails web development framework &lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://www.methodsandtools.com/archive/archive.php?id=47"&gt;http://www.methodsandtools.com/archive/archive.php?id=47&lt;/a&gt;&lt;br /&gt;</description>
      <pubDate>Mon, 16 Apr 2007 05:07:12 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>Cambrige Prefix Calculator</title>
      <link>http://www.programmersheaven.com/mb/ruby/356224/356224/ReadMessage.aspx</link>
      <description>I've been given this assignment to implement a cambridge prefix calculator using ruby and I'm having trouble getting started. If you could please provide any helpful methods to try or any helpful information it would be greatly appreciated.&lt;br /&gt;</description>
      <pubDate>Sun, 18 Mar 2007 18:04:04 -0700</pubDate>
      <category>Ruby</category>
    </item>
    <item>
      <title>How can Ruby search for files on my Windows network computers?</title>
      <link>http://www.programmersheaven.com/mb/ruby/343162/343162/ReadMessage.aspx</link>
      <description>I currently use a Python Script that looks across my Windows network for computers having a specific out-of-date file.  The idea is to run the script, get a list of computers with the out-of-date application, and then replace the application on the identified computers.  The script generally works, but I would like to shift to using Ruby as our primary scripting language.&lt;br /&gt;
&lt;br /&gt;
Any ideas?&lt;br /&gt;
&lt;br /&gt;
Thanks in advance.&lt;br /&gt;</description>
      <pubDate>Tue, 15 Aug 2006 08:20:00 -0700</pubDate>
      <category>Ruby</category>
    </item>
  </channel>
</rss>