无法在 Ubuntu 20.04 上安装 Shopify CLI
Can't install Shopify CLI on Ubuntu 20.04
您好 我在 Ubuntu 20.04 上安装 Shopify CLI 时遇到问题,我不知道如何解决,我从 Shopify 提供的 GitHub 下载 .deb 文件到安装 Shopify CLI,当我尝试安装它时出现此错误
root@cleverchoice:/home/stefan/Downloads# ls
ngrok-stable-linux-amd64 shopify-cli-2.6.3.deb zadatak-20210817T091652Z-001
root@cleverchoice:/home/stefan/Downloads# sudo apt-get install /home/stefan/Downloads/shopify-cli-2.6.3.deb
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'shopify-cli' instead of '/home/stefan/Downloads/shopify-cli-2.6.3.deb'
The following NEW packages will be installed:
shopify-cli
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/956 B of archives.
After this operation, 0 B of additional disk space will be used.
Get:1 /home/stefan/Downloads/shopify-cli-2.6.3.deb shopify-cli all 2.6.3 [956 B]
(Reading database ... 209097 files and directories currently installed.)
Preparing to unpack .../shopify-cli-2.6.3.deb ...
Building native extensions. This could take a while...
ERROR: Error installing shopify-cli:
ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.7.0/gems/ffi-1.15.4/ext/ffi_c
/usr/bin/ruby2.7 -I /usr/lib/ruby/2.7.0 -r ./siteconf20211012-33803-1ymrqv7.rb extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h
You might have to install separate package for the ruby development
environment, ruby-dev or ruby-devel for example.
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.7.0/gems/ffi-1.15.4 for inspection.
Results logged to /var/lib/gems/2.7.0/extensions/x86_64-linux/2.7.0/ffi-1.15.4/gem_make.out
dpkg: error processing archive /home/stefan/Downloads/shopify-cli-2.6.3.deb (--unpack):
new shopify-cli package pre-installation script subprocess returned error exit status 1
Errors were encountered while processing:
/home/stefan/Downloads/shopify-cli-2.6.3.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
我在 Ubuntu 20.04
上找到了我没有安装 Ruby 的答案
sudo apt update
sudo apt install ruby-full
ruby --version
sudo apt update
sudo apt install git curl autoconf bison build-essential \
libssl-dev libyaml-dev libreadline6-dev zlib1g-dev \
libncurses5-dev libffi-dev libgdbm6 libgdbm-dev libdb-dev
您好 我在 Ubuntu 20.04 上安装 Shopify CLI 时遇到问题,我不知道如何解决,我从 Shopify 提供的 GitHub 下载 .deb 文件到安装 Shopify CLI,当我尝试安装它时出现此错误
root@cleverchoice:/home/stefan/Downloads# ls
ngrok-stable-linux-amd64 shopify-cli-2.6.3.deb zadatak-20210817T091652Z-001
root@cleverchoice:/home/stefan/Downloads# sudo apt-get install /home/stefan/Downloads/shopify-cli-2.6.3.deb
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'shopify-cli' instead of '/home/stefan/Downloads/shopify-cli-2.6.3.deb'
The following NEW packages will be installed:
shopify-cli
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/956 B of archives.
After this operation, 0 B of additional disk space will be used.
Get:1 /home/stefan/Downloads/shopify-cli-2.6.3.deb shopify-cli all 2.6.3 [956 B]
(Reading database ... 209097 files and directories currently installed.)
Preparing to unpack .../shopify-cli-2.6.3.deb ...
Building native extensions. This could take a while...
ERROR: Error installing shopify-cli:
ERROR: Failed to build gem native extension.
current directory: /var/lib/gems/2.7.0/gems/ffi-1.15.4/ext/ffi_c
/usr/bin/ruby2.7 -I /usr/lib/ruby/2.7.0 -r ./siteconf20211012-33803-1ymrqv7.rb extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h
You might have to install separate package for the ruby development
environment, ruby-dev or ruby-devel for example.
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.7.0/gems/ffi-1.15.4 for inspection.
Results logged to /var/lib/gems/2.7.0/extensions/x86_64-linux/2.7.0/ffi-1.15.4/gem_make.out
dpkg: error processing archive /home/stefan/Downloads/shopify-cli-2.6.3.deb (--unpack):
new shopify-cli package pre-installation script subprocess returned error exit status 1
Errors were encountered while processing:
/home/stefan/Downloads/shopify-cli-2.6.3.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
我在 Ubuntu 20.04
上找到了我没有安装 Ruby 的答案sudo apt update
sudo apt install ruby-full
ruby --version
sudo apt update
sudo apt install git curl autoconf bison build-essential \
libssl-dev libyaml-dev libreadline6-dev zlib1g-dev \
libncurses5-dev libffi-dev libgdbm6 libgdbm-dev libdb-dev