SitePoint Sponsor

User Tag List

Results 1 to 22 of 22

Thread: Beyond The Type

Hybrid View

  1. #1
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Beyond The Type

    Has anyone worked on this tutorial?

    http://www.beyondthetype.com/rails/2...-ruby-on-rails

    because I got stuck at the first hurdle, if anyone can help me that would be great.

  2. #2
    SitePoint Enthusiast
    Join Date
    Feb 2006
    Posts
    28
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    1) are you on windows or linux?

    2) do you have rails and ruby installed and added to your path? <what does ri or ruby or irb produce on a console>
    3) how do I do this? That depends on the question 1) and im not going to answer both at once.

  3. #3
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    1) I am on windows
    2) As for the console, I navigated to rails directory and then basecamp directory ran ruby script/console, and the screenshot attached is the result.

    Hope this can help.
    Attached Images Attached Images

  4. #4
    Non-Member
    Join Date
    Jul 2005
    Posts
    606
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Did you do gem install xml-simple ?

  5. #5
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It wouldn't let me, do I install it withing the rails/basecamp directory?

  6. #6
    SitePoint Guru silver trophy Luke Redpath's Avatar
    Join Date
    Mar 2003
    Location
    London
    Posts
    794
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It seems to be failing to load the basecamp library - is basecamp.rb in your lib dir?

  7. #7
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It is in there

    But I had it as basecamp.rb.rb



    Could that be the problem?

  8. #8
    Non-Member
    Join Date
    Jul 2005
    Posts
    606
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

  9. #9
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,235
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Quote Originally Posted by NickToye

    Could that be the problem?
    yeah

  10. #10
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok, I did a gem install xml-simple and it said this:

    local gem file not found
    Attempting remote installation of xml-simple
    Error: While executing gem ... (socket area)
    getaddrinfo: no address associated with hostname.

  11. #11
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Turns out it was Norton AV that was causing problems, so I disabled that and it worked.

  12. #12
    SitePoint Guru
    Join Date
    Aug 2005
    Posts
    986
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sudo is linux. Which script is causing the error?

  13. #13
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Well i'm running through the tutorial linked at the start of this thread.

    Then when I run the script/console

    I don't get what is expected in the tutorial.

  14. #14
    SitePoint Guru silver trophy Luke Redpath's Avatar
    Join Date
    Mar 2003
    Location
    London
    Posts
    794
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This might not be that helpful, but if you could get hold of a Linux machine (or even better a Mac) to develop on you'll appreciate it. Developing Rails apps on Windows is horrible - its largely inferior console/cmd line doesn't help.

  15. #15
    Non-Member
    Join Date
    Jul 2005
    Posts
    606
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Luke is right, but getting a Nix box just to develop a rails app is a bit of a pain. Personally I think Windows can do the job, the worst thing is the lack of a quality, lightweight IDE like textmate for the mac

    Try without the sudo i.e.
    gem install xml-simple

    If that doesn't work try:
    ruby gem install xml-simple

  16. #16
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    the gem install worked

    But when I run the script/console it doesn't show what is in the tut.

    I do agree about Mac's and its something that I am looking to do within the next month or so. Its not just for Ruby its for all web app, speed of processor and because they are just that cool!

  17. #17
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok, I started again, I created the basecamp application, and then installed the gem simple-xml from within the rails directory not the basecamp directory.

    It seemed to install

    I have attached a screenshot of what happens when I run the script/console.
    Attached Images Attached Images

  18. #18
    Non-Member
    Join Date
    Jul 2005
    Posts
    606
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Those are just warnings. I imagine things should still work fine.

  19. #19
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yeah,

    But this isn't showing:

    session = Basecamp.new('beyondthetype.updatelog.com', 'username', 'password')
    puts "projects: #{session.projects.length}"
    projects: 1

  20. #20
    Non-Member
    Join Date
    Jul 2005
    Posts
    606
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm a noob myself but would imagine you are supposed to actually type that into the command line puts "projects: #{session.projects.length}" is saying output the number of items in the projects array, hence the next line should be automatic....i.e. it will display projects: 1 (or however many projects you have)

  21. #21
    SitePoint Guru
    Join Date
    Aug 2004
    Location
    Port Sunlight
    Posts
    815
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    nope, I don't think so


Bookmarks

Posting Permissions

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