I got the below error on trying to start Jekyll server
Error: uninitialized constant FFI::Platform::CPU
I tried reinstalling Jekyll server and its dependencies, but no luck. Could someone help me to get around this issue? Thanks.
I am using ubuntu=18.04, jekyll=3.8.6
anil#anil:~/customer-churn$ jekyll serve
Configuration file:
~/customer-churn/_config.yml
Source: ~/customer-churn
Destination: ~/customer-churn/_site
Incremental build: disabled. Enable with --incremental
Generating... done in 0.597 seconds.
jekyll 3.8.6 |
Error: uninitialized constant FFI::Platform::CPU
I guess this problem occurs if you've installed Jekyll through apt. In that case a bundle update won't work immediately after an apt remove. Try the following approach:
Uninstall Jekyll first:
sudo apt remove jekyll*
Clean-up your dependency libs:
sudo apt autoremove
Then in your project directory run:
bundle update
Positively, then jekyll serve should work for you.
I solved the problem by reinstalling the Jekyll and its dependencies using some steps which are given in the below link -
http://michaelchelen.net/81fa/install-jekyll-2-ubuntu-14-04/
I just want to thanks all who have to help and giving guidance to me from your busy schedule.
I was not able to solve this simply by running bundle update or reinstalling jekyll and dependencies with apt as other answers suggested.
What did work was to
remove all versions of jekyll and dependencies with sudo gem uninstall ...,
remove jekyll and all dependencies with apt-get remove ...,
then reinstall jekyll and dependencies with apt-get install ...,
and then run bundle update in the project directory.
Then only bundle exec jekyll serve works, and jekyll build still presents the same error.
Try removing Jekyll using apt (if you've installed it that way):
sudo apt remove jekyll*
Then go to your project, type:
bundle update
and only then:
jekyll serve
Found this answer here:
https://www.gitmemory.com/issue/jekyll/jekyll/7712/502572155
I ran into the same problem. After running bundle exec jekyll serve --trace, I noticed that some packages were being loaded from the /usr/lib/ruby/vendor_ruby directory. So, I removed the /usr/lib/ruby/vendor_ruby directory (keeping a backup copy of it in my home directory, just in case). This, followed by bundle install, fixed the issue for me.
Related
Trying to run pod install in a new React Native project and getting this error. Ruby is installed with brew
I have installed chruby and ruby-install, which I have then used to install ruby-2.7.5 cocopods, ffi and bundler. When trying bundler to install I get this error:
warn Multiple Podfiles were found: ios/Podfile,vendor/bundle/ruby/2.7.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/Podfile. Choosing ios/Podfile automatically. If you would like to select a different one, you can configure it via "project.ios.sourceDir". You can learn more about it here: https://github.com/react-native-community/cli/blob/master/docs/configuration.md
[Codegen] Generating ./build/generated/ios/React-Codegen.podspec.json
fatal: not a git repository (or any of the parent directories): .git
Analyzing dependencies
Fetching podspec for `DoubleConversion` from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`
[Codegen] Found FBReactNativeSpec
Fetching podspec for `RCT-Folly` from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`
Fetching podspec for `boost` from `../node_modules/react-native/third-party-podspecs/boost.podspec`
Fetching podspec for `glog` from `../node_modules/react-native/third-party-podspecs/glog.podspec`
Fetching podspec for `hermes-engine` from `../node_modules/react-native/sdks/hermes/hermes-engine.podspec`
[!] Couldn't determine repo type for URL: `https://cdn.cocoapods.org/`: Permission bits for '/Users/macbook/.netrc' should be 0600, but are 644
So I put out a bounty on this because I couldn't figure it out for ages. Until I did. (Hopefully this fix works for everyone else)
First when I ran xcode-select -p it was returning /Library/Developer/CommandLineTools
However this looked odd as another an answer here seemed to suggest that maybe this was causing an issue. It ended up that I just hadn't set my CLI tools correctly as described in the react native docs. Since it only had one option in the dropdown I assumed that the CLI tools were already set. However when I went back and specifically clicked on the one option, it made changes to my system.
Now running xcode-select -p returns /Application/Xcode.app/Contents/Developer
TL;DR : Open Xcode, go to 'Settings...' in the menu bar. Then go to the 'Locations' tab and click on the 'Command Line Tools' dropdown and click on the latest version (click on a version even if it seems like a version is already set). Now try your pod install again!
Probably this answer(https://stackoverflow.com/a/69427481/8988448) would solve your issue. Looks like you haven't given proper permissions.
run chmod 600 ~/.netrc and once it is done, run pod install.
Got same error as below:
✔ Downloading template
✔ Copying template
✔ Processing template
ℹ Installing dependencies
✔ CocoaPods (https://cocoapods.org/) is not installed. CocoaPods is necessary for the iOS project to run correctly. Do you want to install it? › Yes, with gem (may require sudo)
✔ Installing CocoaPods
✔ Installing Bundler
✖ Installing CocoaPods dependencies (this may take a few minutes)
error warn Multiple Podfiles were found: ios/Podfile,vendor/bundle/ruby/2.7.0/gems/cocoapods-core-1.11.3/lib/cocoapods-core/Podfile. Choosing ios/Podfile automatically. If you would like to select a different one, you can configure it via "project.ios.sourceDir". You can learn more about it here: https://github.com/react-native-community/cli/blob/master/docs/configuration.md
✖ Installing CocoaPods dependencies (this may take a few minutes)
error Error: Looks like your iOS environment is not properly set. Please go to https://reactnative.dev/docs/next/environment-setup and follow the React Native CLI QuickStart guide for macOS and iOS.
Environment: macOS Catalina 10.15.7
Through gem installed cocoapods like below.
rn sudo gem install -n /usr/local/bin cocoapods
Password:
When run react-native init myproj, choose gem to install coacopods again.
Hello once I also had same issue . I have resolve it.Follow this step it would work .
This error is cause by installing same package multiple time in single project
Try to remove that package from project and reinstall that project.
Try to uninstall ruby-2.7.5
yarn remove package name
yarn add package name
or
npm uninstall package name
npm install package name
and
cd ios && pod install && cd ..
npx react-native run-ios
I am trying to install cocoapods onto my computer. I did the following:
sudo gem update--system
Password:
and I got the following text:
ERROR: While executing gem ... (Gem::CommandLineError)
Unknown command update--system
Kind of confused as to how to fix this.
If you are trying to update gems before installing cocoapods, you need to do
sudo gem update --system
You forgot the space between update and --system.
To install cocoapods, you need to use the following command:
sudo gem install cocoapods
Trying to install CocoaPods from the terminal:
$ sudo gem install cocoapods
After entering my root password, nothing happens.
How can I debug that?
For others wondering the same, installing the gem takes forever. If you run:
export GEM_HOME=~/.gems
export PATH=$GEM_HOME/bin:$PATH
gem install cocoapods -V
Installing with flag V enables verbose output which will let you see all the output as it is going through the download and install, it's quite a lot.
update gem to the newest release using
sudo gem update --system and it should work a bit faster
I had to wait at least 5 minutes before:
Building native extensions. This could take a while...
Appears
You should do it in two separated commands:
First:
gem update
Then:
export GEM_HOME=~/.gems
export PATH=$GEM_HOME/bin:$PATH
gem install cocoapods
It's not stuck, it's downloading file for ruby from the internet. you can check this by following below steps:
Open Activity Monitor
Select Network option
Check below Google Chrome. (ruby downloading)
Try Installing latest Git version from
https://git-scm.com/downloads
This worked for me
Write the following commands in Terminal:
export GEM_HOME=~/.gems
export PATH=$GEM_HOME/bin:$PATH
gem install cocoapods
Set the path of the project with the command cd path/to/project
pod init
Open podfile
Add appropriate pod
pod install
I have successfully ran the shapado rails application on my local system(am using ubuntu). But While running the bundle install, it fails with following error
configure: error: Neither uuid/uuid.h nor uuid.h found - required for
brass, chert and flint (you may need to install the uuid-dev,
libuuid-devel or e2fsprogs-devel package)
Then I installed the packages by using
sudo apt-get install uuid-dev
sudo apt-get install libqt4-dev
While running the rake task
rake bootstrap RAILS_ENV=development
Got some nil error and fixed the same by applying below patch
Called id for nil
After this, I can able to run the application on my local successfully.
When I tried to deploy on Heroku it fails with
configure: error: Neither uuid/uuid.h nor uuid.h found - required for brass, chert and flint (you may need to install the uuid-dev, libuuid-devel or e2fsprogs-devel package)
it tries to install the gem 'xapian-ruby', '1.2.7.1' and fails due to unavailable of packages.
Is any one facing the same issue. Suggest me to sort this out.
Deploying shapado to heroku would require you to make a custom buildpack that has the binary dependencies that shapado needs built in. Instructions on how to do that can be found here https://blog.heroku.com/archives/2012/11/13/hacking-buildpacks. It is possible though.
gem install heroku failed with following message and I have tried the solution here, but it failed also. Is there any other way I can install Heroku?
WARNING: RubyGems 1.2+ index not found for: http://gems.rubyforge.org/
RubyGems will revert to legacy indexes degrading performance.
ERROR: could not find gem heroku locally or in a repository.
Heroku now offers a standalone client, called the Heroku Toolbelt. Check out https://toolbelt.heroku.com/ for current installation instructions.
you should be able to bypass the problem by downloading the heroku gem from rubygems.org and install from the local copy.
go to http://rubygems.org/gems/heroku and click the download link to download version 1.8.5
then move into the download folder and do a gem install --local heroku-1.8.5.gem ,but follow the instruction to install the dependency first
Updating the gem to version 1.3.6 seem solve the problem.
However, gem update --system does not work on Ubuntu platforms, and apt-get install rubygems1.8 always bring you to version 1.2.0.
Here is the trick to update your gems to latest one,1.3.6, by the time of writing:
sudo gem install rubygems-update
sudo update_rubygems
And the credit goes here.
Finally, by all means avoid installing the gems manually, my experience taught me.
Seems like your Rubygems version is not up to date.
Try sudo gem update --system and/or sudo gem install rubygems-update; sudo update_rubygems before trying to install the heroku gem.
Alternately, if you're running Debian and cannot use gem update --system, try installing a version of rubygems that is >1.2 from backports. I used aptitude -t lenny-backports install rubygems and then rubygems could actually access the online repository.
To install Heroku in all currently supported versions of Ubuntu open the terminal and type:
sudo snap install --classic heroku
This installs the heroku snap package successfully, and it is the recommended way of installing Heroku CLI in Ubuntu at the Heroku Dev Center website. When this was posted sudo snap install --classic heroku installs the latest version of Heroku.