Results 1 to 10 of 17

Thread: Ruby on Rails

Hybrid View

  1. #1

    Cool Ruby on Rails

    Sign me up!

    -taresaco

  2. #2
    Join Date
    Feb 2006
    Posts
    177

    Default

    Send an email to rando@bluehost.com with your domain name and I'll get you moved over to box85 so you can test it.

  3. #3

    Default What am I doing wrong...

    Is anyone else using Ruby? I tried this:

    taresaco@taresa.com [~]# ls -la calc.rb
    -rw-r--r-- 1 taresaco taresaco 8 Feb 9 16:09 calc.rb
    taresaco@taresa.com [~]# ruby calc.rb
    -bash: ruby: command not found

    calc.rb is just one line:

    puts 1+2

    Maybe I'm looking at the wrong Ruby tutorial. Has anyone else had success?

  4. #4
    Join Date
    Feb 2006
    Posts
    177

    Default

    Ruby isn't in your path for some reason. It's installed to /usr/local/bin/ruby.

  5. #5

    Default

    taresaco@taresa.com [~]# cd usr/local/bin/ruby
    -bash: cd: usr/local/bin/ruby: No such file or directory

    Que?

  6. #6

    Default

    If I need to tell bash where Ruby is... I'm not really sure how to do that, but I'll look it up. Is that the case?

  7. #7
    Join Date
    Feb 2006
    Location
    Metro DC, United States
    Posts
    100

    Default

    Quote Originally Posted by Taresa
    taresaco@taresa.com [~]# cd usr/local/bin/ruby
    -bash: cd: usr/local/bin/ruby: No such file or directory

    Que?
    A couple things here...

    First, you're missing the leading '/'. You're telling the cd command to go to the usr directory under your current working directory as opposed to the system usr directory. Second, you can't cd to that anyway (it'll throw another error) because it's not a directory. If you want to see if the ruby executable is really there, try 'ls /usr/local/bin | grep ruby'.

    Quote Originally Posted by Taresa
    If I need to tell bash where Ruby is... I'm not really sure how to do that, but I'll look it up. Is that the case?
    If you need to tell bash about /usr/local/bin, put the following line in your ~/.bashrc (and your ~/.bash_profile if you don't have that pointing at your .bashrc):
    Code:
    PATH=/usr/local/bin:${PATH}; export PATH
    Here's a decent intro to bash. Environment settings are dealt with briefly towards the bottom of the page. And here's a link to a bash quick reference card (well, cards).


    Edit: Looks like DrSuSE beat me to it. That's what happens when you're interrupted halfway through writing a post. :)
    Eric :)
    ----
    "If you want to know what a man's like, take a good look at how he treats his inferiors, not his equals."
    ~Sirius Black, Harry Potter and the Goblet of Fire

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •