0

I'm trying to install datamapper and I'm getting this error:

Whirlwind:Desktop AGreen$ gem install data_mapper
ERROR:  While executing gem ... (Errno::EACCES)
    Permission denied - /Users/AGreen/.rvm/gems/ruby-1.9.2-p320/gems/bcrypt-ruby-3.0.1/.gitignore

I also tried to install it this way:

Whirlwind:Desktop AGreen$ gem install datamapper
ERROR:  While executing gem ... (Errno::EACCES)
    Permission denied - /Users/AGreen/.rvm/gems/ruby-1.9.2-p320/gems/bcrypt-ruby-3.0.1/.gitignore

Does anyone know how I can fix this?

matt
  • 78,533
  • 8
  • 163
  • 197
skyfaerie
  • 33
  • 7

2 Answers2

0

Seems like a permission issue to me.

To check:

ls -l ~/.rvm

Should all belong to you.

To fix:

sudo chown -R AGreen /Users/AGreen/.rvm

You may also consider chown'ing your whole home directory.

phil pirozhkov
  • 4,740
  • 2
  • 33
  • 40
-1

If you're on linux, you'll need to prefix your command with sudo.

Try

sudo gem install data_mapper
Anthony DeSimone
  • 1,994
  • 1
  • 12
  • 21