wow this is powerful, can this be used to activate and deactivate plugin at scheduled times ? for example updraft / wpallimport plugin only activated just when they are needed.
@WPCasts do you know if it is possible to export a sample page/post containing lots of acf fields/flex content to a file and import it in all subsites of a multisite network with WpCLI?
Some more background info for command line novices would be great. Are you using SSH and installing WP CLI onto a remote server? Or installing it onto your local machine in something like Terminal then connecting to a remote server?
This CLI seems super powerful. Thanks. I could use a super beginner introduction, "Hello World". I don't even understand where to install CLI, is it WP plugin ? Does it go on the hosting server ? What's the syntax ? What is curl ? Where do I open that CLI ? What are the prerequisites. Thanks !
More content on the cli would be sweet, I’ve recently switched to spinupWP for hosting and use the cli to auto activate wp maintenance mode when a git deploy is taking place, good stuff!
Did you find a solution to this? I would wp db export, copy files via rsync and then wp db import, then wp search-replace the database to change URLs. That does work, but maybe there's a better way. I use wordmove for this purpose, instead of WP CLI.
Hey Alex great one again defiantly looking forward for more wp-cli. just one question how did you open a terminal connected to site ground without SSH? plus do I need to install wp-cli on Siteground its not that clear from the video. cheers in advance
The WP-CLI is pre-installed on Siteground. And here is an article on getting SSH access to your server: www.siteground.com/kb/how_to_log_in_to_my_shared_account_via_ssh_in_linux/
For any devs working with "Local" from localwp.com you will need to right-click on the site name and select "Open Site Shell" in order to run certain commands like "wp plugin". Before using the "Open Site Shell" option I received an error saying "Error establishing a database connection". I hope this helps some of you.
when i try to move "sudo mv wp-cli.phar /usr/local/bin/wp" got error "-bash: sudo: command not found ". am using ssh using putty. and some thing is different from you, am using sitground shared hosting . Shell: /bin/bash PHP binary: /usr/local/php73/bin/php-cli PHP version: 7.3.26 php.ini used: /usr/local/php73/lib/php.ini WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli WP-CLI vendor dir: phar://wp-cli.phar/vendor WP_CLI phar path: /home/customer WP-CLI packages dir: WP-CLI global config: WP-CLI project config: WP-CLI version: 2.4.0
Thanks for the vid. Did you add the CLI to a local computer or to server? How do you connect local to online? Would this be suitable for shared hosting?
Thanks for watching! Would you be interested in more WP-CLI content?
wow this is powerful, can this be used to activate and deactivate plugin at scheduled times ? for example updraft / wpallimport plugin only activated just when they are needed.
Yes Yes Yes... I would like to have more on CLI. I also did some videos for CLI ☺. It would be great if you can check out my playlist.
Yes, please. You’ve got my attention to learn more.
@WPCasts do you know if it is possible to export a sample page/post containing lots of acf fields/flex content to a file and import it in all subsites of a multisite network with WpCLI?
Yes !
I'd be very interested in more WP-CLI stuff
WP-CLI is one of my fav. I also made some videos. You can checkout my playlist for that.
SAME!
This is great. I would definitely be keen for more videos on WP CLI. Cheers!
I would be interested to see more videos on this topic 👍
Some more background info for command line novices would be great. Are you using SSH and installing WP CLI onto a remote server? Or installing it onto your local machine in something like Terminal then connecting to a remote server?
Would love to see another video of more on wp-cli
Great idea, wp cli is an essential node in learning wordpress.
I would love to see more about this topic
This CLI seems super powerful. Thanks. I could use a super beginner introduction, "Hello World". I don't even understand where to install CLI, is it WP plugin ? Does it go on the hosting server ? What's the syntax ? What is curl ? Where do I open that CLI ? What are the prerequisites. Thanks !
I've been always fan of WP-CLI.
More content on the cli would be sweet, I’ve recently switched to spinupWP for hosting and use the cli to auto activate wp maintenance mode when a git deploy is taking place, good stuff!
how can i manage existing wordpress through wp-cli? None of google resources say about that. Just about starting from scratch :)
how did you connect that to your live site??
Yes please more! How to transfer database with CLI or the entire site.
Did you find a solution to this? I would wp db export, copy files via rsync and then wp db import, then wp search-replace the database to change URLs. That does work, but maybe there's a better way. I use wordmove for this purpose, instead of WP CLI.
which OS do you use?
I'm on OSX
Awesome video! thank you for share your knowledge
Totally dug this! More Please! (I don't know what I don't know!)
You got it!
Hey Alex great one again defiantly looking forward for more wp-cli. just one question how did you open a terminal connected to site ground without SSH?
plus do I need to install wp-cli on Siteground its not that clear from the video. cheers in advance
The WP-CLI is pre-installed on Siteground. And here is an article on getting SSH access to your server: www.siteground.com/kb/how_to_log_in_to_my_shared_account_via_ssh_in_linux/
@@WPCasts Thanks Alex sorry fpr the late reply cheers I'l check it out :)
Its sooooo amazing!!! Please keep it up with Bedrock/Sage content too please
Cool, keep going with wp cli! Also backup/restore or maybe automated backup with server cron job will be nice..
awesome! More, please ;)
Please do cover more
Does this need a VPS as a minimum?
For any devs working with "Local" from localwp.com you will need to right-click on the site name and select "Open Site Shell" in order to run certain commands like "wp plugin". Before using the "Open Site Shell" option I received an error saying "Error establishing a database connection". I hope this helps some of you.
Thank you for this!
@@jasonetaylor you’re welcome! I was scratching my head for a while before I figured it out.
thanks
Awesomeee!
What IDE tool are you using in this video to execute WP CLI?
Is it Visual Studio Code?
He is clearly using terminal on his Mac
@@tiaan_va thanks for commenting. I cannot believe its been a year since this comment. I figured it out already during that time after I commented.
3:09 - nobody should be SSH'ing straight into a running container. Those are ephemeral. Asid from that, this is a great video.
Like before watch.
Sure, but even after this watching. I don't have any idea how to connect with my hostgator account???
Can you please help me.
for an absolute noob - what is sudo and how do I find that password?
Awesome 👍😀
when i try to move "sudo mv wp-cli.phar /usr/local/bin/wp" got error "-bash: sudo: command not found
". am using ssh using putty.
and some thing is different from you, am using sitground shared hosting .
Shell: /bin/bash
PHP binary: /usr/local/php73/bin/php-cli
PHP version: 7.3.26
php.ini used: /usr/local/php73/lib/php.ini
WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli
WP-CLI vendor dir: phar://wp-cli.phar/vendor
WP_CLI phar path: /home/customer
WP-CLI packages dir:
WP-CLI global config:
WP-CLI project config:
WP-CLI version: 2.4.0
LOL. I can't even figure out how to curl a file!
Woohooo! Global spelling-correction is now a thing!
It would be great give some clues for Windows users. Not everyone in the world uses mac
Try using Git Bash on Windows and then you can follow along
They will be soon enough. You should get onboard :)
Thanks for the vid. Did you add the CLI to a local computer or to server? How do you connect local to online? Would this be suitable for shared hosting?
bhargavb.wordpress.com/2016/12/24/install-wp-cli-on-windows/
A suggestion for good use of wp-cli - generating fake content in a dev environment. I use this wp-cli extension: github.com/nlemoine/wp-cli-fixtures
I’m sorry it does not work.
This tutorial IS NOT COMPLETE... you didn't teach what you used to open that terminal... You did teach us to use Putty to open SSH