Menu

Post image 1
Post image 2
1 / 2
0

'Command not found' — and what's really blocking WP-CLI

DEV Community: tutorial·Susumu Takahashi·3 months ago
#E99OWfpp
#dev#file#phar#fullscreen#manager#article
Reading 0:00
15s threshold

"I downloaded wp-cli.phar , uploaded it to ~/bin/wp , SSH'd in, and ran wp . Got -bash: wp: command not found . The file is right there. Why?" If you've set up WP-CLI on a shared host using a browser-based file manager, you may have hit exactly this. The file exists, permissions are 755, size is 6.8 MB (matches the official PHAR). And yet it refuses to run. The "command not found" message can hide an entirely different problem underneath. The file is there, but nothing runs After SSHing in, you can confirm the file exists: $ ls -la ~/bin/wp -rwxr-xr-x 1 c1234567 c1234567 7142777 May 8 10:00 /home/c1234567/bin/wp $ wp --info -bash : wp: command not found Enter fullscreen mode Exit fullscreen mode You might suspect ~/bin isn't on PATH (the environment variable that lets you run a command by name alone).…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.

Read More