Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Manage WordPress Easily With WP-CLI
Search
Ajit Bohra
November 05, 2017
Technology
0
570
Manage WordPress Easily With WP-CLI
Workshop at WordCamp Nashik 2017, Ajit Bohra, Hardeep Asrani & Gagan Deep Singh
Ajit Bohra
November 05, 2017
Tweet
Share
More Decks by Ajit Bohra
See All by Ajit Bohra
Laravel x WordPress
ajitbohra
0
22
Getting Good With WordPress Playground
ajitbohra
0
89
Embracing WordPress Packages
ajitbohra
0
56
Laravel: Launcher For Your Next Big Idea
ajitbohra
1
290
LaravelLiveIn Mumbai Meetup December 2018
ajitbohra
0
52
Gutenberg For Bloggers & Developer
ajitbohra
0
39
Finding A Right Home For WordPress
ajitbohra
1
580
Tools Of Trade For WordPress Developer
ajitbohra
0
440
Making Money With WordPress
ajitbohra
0
590
Other Decks in Technology
See All in Technology
Webアプリケーションにオブザーバビリティを実装するRust入門ガイド
nwiizo
6
740
おやつは300円まで!の最適化を模索してみた
techtekt
PRO
0
290
会社紹介資料 / Sansan Company Profile
sansan33
PRO
6
380k
Codeful Serverless / 一人運用でもやり抜く力
_kensh
7
370
今!ソフトウェアエンジニアがハードウェアに手を出すには
mackee
11
4.6k
Django's GeneratedField by example - DjangoCon US 2025
pauloxnet
0
120
バイブスに「型」を!Kent Beckに学ぶ、AI時代のテスト駆動開発
amixedcolor
2
520
5分でカオスエンジニアリングを分かった気になろう
pandayumi
0
210
生成AI時代のデータ基盤設計〜ペースレイヤリングで実現する高速開発と持続性〜 / Levtech Meetup_Session_2
sansan_randd
1
150
Rustから学ぶ 非同期処理の仕組み
skanehira
1
130
Automating Web Accessibility Testing with AI Agents
maminami373
0
1.2k
エラーとアクセシビリティ
schktjm
1
1.2k
Featured
See All Featured
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
131
19k
Building a Scalable Design System with Sketch
lauravandoore
462
33k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
8
520
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
111
20k
Rails Girls Zürich Keynote
gr2m
95
14k
Automating Front-end Workflow
addyosmani
1370
200k
A designer walks into a library…
pauljervisheath
207
24k
Into the Great Unknown - MozCon
thekraken
40
2k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
49
3k
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
Transcript
Manage WordPress Easily with WP-CLI Ajit Bohra, Hardeep Asrani &
Gagan Deep Singh
How many of you are Command Line users?
How many of you are using WP-CLI?
What is WP-CLI?
Why not WP-CLI?
Which one was easier?
Expectations & Takeaways
Let’s get started!
Install WP-CLI # Install WP-CLI $ curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar #
Make the file executable $ chmod +x wp-cli.phar # Move it to somewhere in your PATH $ sudo mv wp-cli.phar /usr/local/bin/wp # Test WP-CLI. $ wp —info Source: wp-cli.org
Command Structure $ wp plugin install wordpress-seo - -activate command
subcommand parameter flag
Useful Commands
Plugin Commands: Install & Activate $ wp plugin install bbpress
- -activate
Plugin Commands: Deactivate $ wp plugin deactivate bbpress
Plugin Commands: Delete $ wp plugin delete bbpress
Theme Commands: Install & Activate $ wp theme install make
- -activate
Theme Commands: Deactivate $ wp theme deactivate make
Theme Commands: Delete $ wp theme delete make
Manage Users: List Users $ wp user list
Manage Users: Create User $ wp user create harry
[email protected]
- -role=author
Manage Users: Change Password $ wp user create bob
[email protected]
--role=author
Manage Users: Delete User $ wp user delete 10
Manage Media: Upload Media $ wp media import https://example.com/image.png
Manage Media: Regenerate Media $ wp media regenerate - -yes
Manage Posts: Create Posts $ wp post create --post_type=page --post_title='A
sample post'
Manage Posts: Edit Posts $ wp post edit 123
Manage Posts: Generate Posts $ wp post generate --count=10 --post_type=page
--post_date=1999-01-04
Export/Import Posts: Generate Posts $ wp export
Export/Import Posts: Generate Posts $ wp import example.wordpress.2016-06-21.xml --authors=create
Search/Replace $ wp search-replace ‘http://old-site.com' ‘http://new-site.com'
Now it’s your time.
Resources http://wp-cli.org/ https://developer.wordpress.org/cli/commands/ https://local.getflywheel.com/ https://commandlinepoweruser.com/ https://serversforhackers.com/ https://mediatemple.net/community/products/dv/204403684/ connecting-via-ssh-to-your-server
Thank you.