Project

General

Profile

Download WP if you need it » History » Version 1

Gareth Eaton, 09/27/2023 08:02 PM

1 1 Gareth Eaton
h1. Download WP if you need it
2
3
Download WP-CLI Phar Archive:
4
5
Run the following command to download the WP-CLI Phar archive:
6
7
8
<pre>
9
curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
10
</pre>
11
12
Make WP-CLI Executable:
13
14
Make the downloaded Phar file executable:
15
16
17
<pre>
18
chmod +x wp-cli.phar
19
</pre>
20
21
Move WP-CLI to a Global Location:
22
23
Move the Phar file to a location in your PATH to make it globally available. For example:
24
25
26
<pre>
27
sudo mv wp-cli.phar /usr/local/bin/wp
28
</pre>
29
30
Note: The exact location may vary depending on your system's configuration. /usr/local/bin is a common location for user-installed executables.
31
32
Verify WP-CLI Installation:
33
34
Verify that WP-CLI is installed correctly by running:
35
36
37
<pre>
38
wp --version
39
</pre>
40
41
You should see the WP-CLI version displayed without any errors.
42
43
By following these steps, you will have a reliable and globally accessible installation of WP-CLI on your system. This method allows you to use WP-CLI to manage your WordPress installations from the command line easily.