{"id":7024,"date":"2014-05-17T00:21:29","date_gmt":"2014-05-17T00:21:29","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2014\/05\/17\/how-do-i-uninstall-bundler-on-aws-difference-btw-local-and-system-wide-gems-collection-of-common-programming-errors\/"},"modified":"2014-05-17T00:21:29","modified_gmt":"2014-05-17T00:21:29","slug":"how-do-i-uninstall-bundler-on-aws-difference-btw-local-and-system-wide-gems-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2014\/05\/17\/how-do-i-uninstall-bundler-on-aws-difference-btw-local-and-system-wide-gems-collection-of-common-programming-errors\/","title":{"rendered":"How do I uninstall bundler on AWS (&amp; difference btw local and system wide gems)-Collection of common programming errors"},"content":{"rendered":"<p>When I run <code>bundle install<\/code> on my AWS instance, I get this syntax error on my gemfile:<\/p>\n<pre><code>Gemfile syntax error:\n\/var\/www\/mheesen.cc\/releases\/20131206072125\/Gemfile:18: syntax error, \nunexpected ':', expecting kEND\n...tter-bootstrap-rails', github: 'seyhunak\/twitter-bootstrap-r...\n                              ^\n<\/code><\/pre>\n<p>This is an error typically associated with me having Ruby 1.8 installed, but by typing <code>ruby -v<\/code> I get <code>ruby 1.9.3<\/code>.<\/p>\n<p>Digging a little further, I read &#8220;error in your Gemfile, and Bundler cannot continue&#8221;, and figured that it could be because my bundler is using a system Ruby rather than a local one. (I&#8217;m not exactly sure how that works, but oh well.)<\/p>\n<p>I thought the best remedy was to uninstall the <code>bundler<\/code> gem and reinstall it and hopefully it will pick up the right bundler with the right Ruby version but trying to uninstall on my project directory gives me this error:<\/p>\n<pre><code>path\/to\/my\/project$ gem uninstall bundler\nERROR:  While executing gem ... (Gem::InstallError)\n    bundler is not installed in GEM_HOME, try:\n    gem uninstall -i \/usr\/local\/rvm\/gems\/ruby-1.9.3-p484@global bundler\n<\/code><\/pre>\n<p>This confirms my suspicion that it&#8217;s using a system-wide bundler, but then trying to uninstall that system-wide bundler gives me a permission error:<\/p>\n<pre><code>gem uninstall -i \/usr\/local\/rvm\/gems\/ruby-1.9.3-p484@global bundler\nRemove executables:\n    bundle\n\nin addition to the gem? [Yn]  Y\nERROR:  While executing gem ... (Gem::FilePermissionError)\n    You don't have write permissions for the \n    \/usr\/local\/rvm\/gems\/ruby-1.9.3-p484@global\/bin directory.\n<\/code><\/pre>\n<p>I tried changing the permissions on the said folder.. didn&#8217;t have the permissions to do that either.<\/p>\n<p>Trying to update bundler on my project also tells me that everything is up to date.<\/p>\n<p>What do I do now? What are my options? I&#8217;m running out of ideas.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When I run bundle install on my AWS instance, I get this syntax error on my gemfile: Gemfile syntax error: \/var\/www\/mheesen.cc\/releases\/20131206072125\/Gemfile:18: syntax error, unexpected &#8216;:&#8217;, expecting kEND &#8230;tter-bootstrap-rails&#8217;, github: &#8216;seyhunak\/twitter-bootstrap-r&#8230; ^ This is an error typically associated with me having Ruby 1.8 installed, but by typing ruby -v I get ruby 1.9.3. Digging a little [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-7024","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/7024","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=7024"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/7024\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=7024"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=7024"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=7024"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}