I am new to Shopify theme development. Currently following the tutorial by Shopify. Everything was going smoothly but I am getting the following error every time I run "Shopify theme serve":
[Note] You cannot use gems with Shopify CLI.
[LoadError] cannot load such file -- wdm
They are disabled.
Please don't modify the CLI locally.
If you would like to contribute to the CLI project, please refer to
https://github.com/Shopify/shopify-cli/blob/main/.github/CONTRIBUTING.md
Please add the following to your Gemfile to avoid polling for changes:
gem 'wdm', '>= 0.1.0' if Gem.win_platform?
X You are not authorized to edit themes on banana-man-co.myshopify.com.
Make sure you are a user of that store, and allowed to edit themes.
Also, I know it says I am not authorized to edit themes but I am pretty sure that I am logged in as the admin. Anybody know how to fix this?
Run
gem install wdm
on the command prompt.
Then you won't see this issue but still see
X You are not authorized to edit themes on banana-man-co.myshopify.com.
Make sure you are a user of that store, and allowed to edit themes.
Follow Caution section on https://shopify.dev/themes/tools/cli/getting-started.
For arch linux where shopify-cli is installed using:
gem install shopify-cli
You need to install the Bundler:
gem install bundler
See more details in archlinux ruby wiki. Hope this helps someone.
Related
I was trying to install Sinatra and I kept on getting this error: You don't have write permissions for the /Library/Ruby/Gems/2.0.0 directory
Thanks to "Installing gem or updating RubyGems fails with permissions error" I installed rbenv. I followed the guide and set my global ruby version, etc. but I continue to get the same error when I try to install gems. When I run gem environment the installation directory for RubyGems is still the system Ruby directory.
Should I update GEM_PATH? Since the rbenv guide doesn't mention anything about that, something makes me think that there is still a problem with my rbenv installation.
Can someone please help me figure this out?
You're not showing us the commands you're using but it smells like you're using sudo to install Sinatra. Don't do that with rbenv or RVM managed Rubies.
Just as in the linked question, using rbenv or RVM allows you have one or more Rubies in your user-space where you can modify them all you want. That means you don't need to use sudo, just use gem install ....
An alternate problem you could be having is you set your global Ruby to be system, which is the version installed by Apple for their use, and which you don't want to modify unless you understand why it's there and what they're using it for. IF you have to change it then sudo would be appropriate but, with rbenv or RVM managing Rubies in your user-space there's really no reason to.
Do NOT use chmod to change the ownership of the vendor installed gems; Again, that's for Apple's use so have fun with the local Rubies instead and leave Apple's alone.
In this case, I quit Terminal and upon reopening, things were working correctly. Probably a good thing to try if you're stuck and are sure you've followed instructions correctly. It's not explicitly mentioned in the material I read but I believe is a good practice in general.
We are working on Predix Mobile SDK.So we are try to set Predix Mobile Development Environment for that we need set UAAC command line-utility .We flowed this link (https://github.com/cloudfoundry/cf-uaac).
For Install we tried like this
gem install cf-uaac
We got error this
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions for the /usr/bin directory.
after that we google about this error but we got nothing .Please guide to us for UAAC CLI.
The cloud foundry cf-uaac cli tool is written in Ruby, so installation is done with gem, the ruby package manager.
You can run gem env from a terminal to find the installation directory for gems which is probably /usr/bin in your case. You wouldn't want to install your gems there as only root has permission to write. If you are on OSX there may even be more to the story.
I'm not sure what OS you are using so can't be too prescriptive, but a few suggestions for you can be found in this previous question to override this default behavior on your system:
Override install location on the commandline --user-install cf-uaac
Edit your ~/.gemrc to include something like this or change to one of the GEM PATHS
Re-install ruby to a different location where you do have write permission
Use ruby version manager rvm if you will be doing lots of ruby dev work and want to switch versions / gems
You can find out lots more about the install command in the rubygems guide if you were interested in learning more.
Hope that gets you going again.
UAAC is the Ruby-based command line interface (CLI) for interacting with the Cloud Foundry User Account and Authentication (UAA)
first install Ruby, you can follow the guidelines (steps 1 & 2) from here:
Ruby for Windows
then run this commend from powershell:
gem install cf-uaac
If you are behind a proxy you should add the source:
gem sources -a http://rubygems.org
I have installed Ruby on my system, and now I want to install Compass. But when I execute the gem install compass command, it shows an error like this:
could not find valid gem 'compass' <>=0> in any repositary
And also:
SocketError: getadressinfo: no such host is known.<http://rubygems.org/latest_specs.4.8.gz>
I don't know what the problem is. If I run ruby -v, it shows the Ruby version. So what's the problem with installing Compass?
Can anyone explain this to me properly? I've searched Google, but all I could find was some proxy problem - and I couldn't understand how to set the proxy at all.
I'm using Windows and a company internet connection, so I don't know the username and password of my proxy.
I was behind a proxy and HumberFrench's solution above helped:
Go to Ruby bin folder:
cd c:/Ruby193/bin
And then install compass gem:
gem install compass --http-proxy http://<proxy_adreess>:<port_of_proxy>
Another tip: am on Aptana Studio, so this could be run from within Aptana's terminal.
Cant up-vote so adding this here.
I had the same problem, finally solved it manually.
Goto the rubygems compass page, and download the gem by clicking the Download link. Scroll down and you will see three Runtime Dependencies. Goto each of them and download those gems also. Put all of them in a directory, and try
gem install downloaded_compass_filename
This should solve your problem.
If it gives an repository not found error message, you can force gem to try local files through the gem --local install option
if you use a proxy, and get error, do it
gem install compass --http-proxy http://<proxy_adreess>:<port_of_proxy>
gem install -h gives you a lor of options
The proxy is the most likely cause. You will have to get permission from the network admin, or manually download compass. For more info, See this SA post.
If you decide to go the manual route here is a link to the RubyGems compass page. This not ideal, but also better than having to write css without compass magic ^^
Good luck!
On windows i had a few instalations of ruby:
C:\ruby187
and
C:\Ruby200-x64
install compass in both places, using:
gem install compass
Try running the install command in the bin folder.
$ cd C:\Your_Ruby_Folder\bin
$ gem install compass
I have same problem and i resolve it with.
Uninstall ruby end deleted folder ruby
Download ruby version 1.9.x
After thet install sass
last stem: install compass
I would like to get going with Compass and Sass on my Dreamhost webspace. Unfortunately it is not part of the provided standard gems so the installation appears to be more complicated. Does anyone have hands on experience with installing and running Compass and Sass on Dreamhost?
I'd appreciate any guidance.
I was facing a similar challenge - installing Sass/Compass on dreamhost shared account - but was able to figure out how to do it. I used these instructions for installing my own copy of RubyGems (although I'm not completely sure that was necessary). Then I just used the following two commands to install sass and compass:
gem install sass
gem install compass
It all went pretty smoothly.
One option is to just precompile your sass (compass compile) on your machine and then upload just the CSS, so you don't actually need compass installed there.
Or, if you're in a ruby project, use bundler. It will install the gems under the project.
If you're using a Dreamhost VPS (I would recommend it over the shared hosting) then you also have sudo access, and you can install it globally by logging in as an admin user (set this up in the panel).
I first had to follow the instructions here to make sure that I had Ruby and Gems installed. Then I installed compass using Gems.
Then I tried to run compass and had some errors...
"Warning: Unable to load CarbonCore.
FSEvents will be unavailable compass"
I found a solution here, but it required me to install RVM via gems first and then following the instructions in the link above.
Is there an easier way to setup/run compass/sass on OSX?
This problem is described in the compass issue tracker. It's not a showtopper because it falls back to another (less efficient) method of watching for file changes that doesn't depend of fsevents. Still, it would be nice to fix, right?
Since you compiled your own version of ruby, you need to enable shared libraries for it as well. This is described on the rubycocoa getting started page.
More details can be found in this google groups discussion, particularly the advice from Brandon Mathis.
Installing last version of Compass gem (0.11.5) seems to solve the problem:
gem install compass
You have to update your gems:
sudo gem update –system