To install Shopify CLI on Linux debian based disros like Ubuntu, Linuxmint, Debian, xubuntu etc, you can follow all terminal commands from below, please make sure have privilege to install apps/software on your system.
Check versions of tools required to install Shopify CLI
ruby -v
git --version
ngrok --version
shopify version
gem list
Update your system first
sudo apt update && sudo apt upgrade -y
Shopify cli is a Ruby gem that you can install if you already have Ruby 2.7.x preinstalled on your system but you don’t have it, you can install it. You should also have git preinstalled and nodejs is also required if you are going to build shopify nodejs app.
Install Ruby First
To install stable version of Ruby, run the following command
sudo apt install ruby
Then git
sudo apt install git
Finally install Shopify CLI gem
gem install shopify-cli
If you are going to build Shopify app then you also need ngrok otherwise you would not able to run the shopify app server
To run shopify app server, install ngrok
First you need to create an ngrok account and then install ngrok and add ngrok token to your app to run your shopify app server.
sudo apt install ngrok