Let’s quickly install wp cli on Debian based Linux distro called Linuxmint. I assume that you have already installed WordPress with PHP, MySQL and web-server (apache2 or other).
PHP, Apache2, and MySQL Version
This is how you check versoins of apache2, php, and mysql installed on my Linuxmint desktop.
WordPress for wp-cli
I have installed WordPress 5.9.1 on my Linuxmint desktop
Install WP-CLI on Linuxmint
You can follow these steps to install wp-cli on any Debian based distro like Ubuntu, Debian, Linuxmint.
I also assume that you have installed curl or wget.
curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
php wp-cli.phar --info
chmod +x wp-cli.phar
sudo mv wp-cli.phar /usr/local/bin/wp
wp --info
Now you should get in return
Update WP-CLI
sudo wp cli update
Quickly Install wp-cli on Linux
Install wp-cli on Windows
Download wp-cli.phar manually and save it to a folder >> c:\wp-cli
Create a file named wp.bat
in c:\wp-cli
with the following contents:
@ECHO OFF
php "c:/wp-cli/wp-cli.phar" %*
Add c:\wp-cli
to your path:
setx path "%path%;c:\wp-cli"
You can now use WP-CLI from anywhere in Windows command line.
Contents
show