Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby Ruby Gems Ruby Gems Gem Installation

Sean Flanagan
Sean Flanagan
33,235 Points

FilePermissionError

Hi. I keep getting the above exception when trying to install a gem. I downloaded a gem then uploaded it to Workspaces, but got the same error. I'm at a loss as to what to do now. I'd appreciate any help.

I've contributed to another thread but had no reply. Here's the link to it:

https://teamtreehouse.com/community/created-a-workspace-tried-installing-money-gem-but-i-keep-getting-filepermissionerror

I've done all the other ten courses on the Ruby track. Since there's either a quiz or a code challenge after each video, would it be better to watch the remaining videos and finish this course and the track?

3 Answers

Seth Reece
Seth Reece
32,867 Points

Hi Sean,

Workspaces for Ruby uses a Ubuntu virtual machine. File permission errors occur when the user does not have write permissions for a file or folder. More about this here. You can type chmod 777 -R /usr/local/lib/ruby/gems then try installing your gem.

Sean Flanagan
Sean Flanagan
33,235 Points

Hi Seth. Just to let you know that I typed what you stated and it worked perfectly. I've given you an up vote and Best Answer. Thanks. :)

The answer is this:

gem install money