`sudo bundle install` will mean that the only user that can start your application or modify it's bundle is root. since that is rarely what you want, we advise against it.
> Any help solving this silly problem would be so greatly appreciated!!!
You have an extremely unusual setup. While bundler is supposed to detect when it needs sudo permissions to install gems automatically, I think something is going wrong due to your setup being unique.
The only reason that "sudo gem install" is suggested on OS X machines is because the default system gems (NOT gems installed via MacPorts or some other way) are owned by root, and there is no way to install them without sudo. Since you are not using system gems, there is no reason for you to need sudo.
I think you can probably work around the problem in one of two ways: either take ownership of /opt/local/lib/ruby/gems/1.8/ and /opt/local/bin/, so you can write to them without sudo, or install you gems with the command `bundle install --path vendor/bundle`. That command will install the gems into the directory vendor/bundle inside your project, and then you won't have permissions issues.
Since Bundler's permission detection is not working in your case, please file a ticket on the Bundler issue tracker following the steps outlined in https://github.com/carlhuda/bundler/blob/master/ISSUES.md.
– Andre
Thanks for the detailed explanation...
> You have an extremely unusual setup. While bundler is supposed to detect when it needs sudo permissions to install gems automatically, I think something is going wrong due to your setup being unique.
>
Really, I thought I was more or less 'mainstream' for OSX....
> The only reason that "sudo gem install" is suggested on OS X machines is because the default system gems (NOT gems installed via MacPorts or some other way) are owned by root, and there is no way to install them without sudo. Since you are not using system gems, there is no reason for you to need sudo.
>
Yeah also I was worrying because next I want to get RVM hooked up and
things will only get weirded...
> I think you can probably work around the problem in one of two ways: either take ownership of /opt/local/lib/ruby/gems/1.8/ and /opt/local/bin/, so you can write to them without sudo, or install you gems with the command `bundle install --path vendor/bundle`. That command will install the gems into the directory vendor/bundle inside your project, and then you won't have permissions issues.
I seem to have solved it... But I can't say for sure what was wrong.
What I did was, I told port to uninstall rubygems. But then I noticed
that within the port universe /opt... I could still find a rubygems
directory under ruby. So I hard deleted that. And then reinstalled
rubygems with port. And from that point on things started working
again... I can't be positive of this chronology, but maybe there's a
useful clue in that story.
Thanks again!
Pito