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
Yoav Farhi - Getting started with WP-CLI - Word...
Search
WordPress Greek Community
November 19, 2016
Programming
1
320
Yoav Farhi - Getting started with WP-CLI - WordCamp Athens 2016
WordPress Greek Community
November 19, 2016
Tweet
Share
More Decks by WordPress Greek Community
See All by WordPress Greek Community
Thanassis Zannias - Flexible WordPress Dev Environment with Docker
wpgr
0
6
Andreas Karavanas - AI Supercharged Landing Pages
wpgr
0
9
Όμορφα, γρήγορα και οικονομικά websites με WordPress
wpgr
0
9
Unlocking creativity - Marilia Darilli
wpgr
0
29
Έλλη Μουχτάρη - Χτίσε το προσωπικό σου brand και απόκτησε τους πελάτες που θες
wpgr
0
21
Ioannis Kastorinis - WooCommerce technical automations in the real world
wpgr
0
32
Christos Paloukas - Cache me if you can, a journey through caching layers in WordPress
wpgr
0
40
Ευάγγελος Πάλλης - Malware Cleanup & Protection
wpgr
0
43
Νίκος Μαυράκης - Κοστολογώντας τη δημιουργικότητα
wpgr
0
29
Other Decks in Programming
See All in Programming
『自分のデータだけ見せたい!』を叶える──Laravel × Casbin で複雑権限をスッキリ解きほぐす 25 分
akitotsukahara
1
480
A2A プロトコルを試してみる
azukiazusa1
2
1.1k
AIコーディング道場勉強会#2 君(エンジニア)たちはどう生きるか
misakiotb
1
240
Systèmes distribués, pour le meilleur et pour le pire - BreizhCamp 2025 - Conférence
slecache
0
100
プロダクト志向なエンジニアがもう一歩先の価値を目指すために意識したこと
nealle
0
110
Gleamという選択肢
comamoca
6
760
童醫院敏捷轉型的實踐經驗
cclai999
0
180
#kanrk08 / 公開版 PicoRubyとマイコンでの自作トレーニング計測装置を用いたワークアウトの理想と現実
bash0c7
1
300
今ならAmazon ECSのサービス間通信をどう選ぶか / Selection of ECS Interservice Communication 2025
tkikuc
17
3.3k
たった 1 枚の PHP ファイルで実装する MCP サーバ / MCP Server with Vanilla PHP
okashoi
1
170
DroidKnights 2025 - 다양한 스크롤 뷰에서의 영상 재생
gaeun5744
3
310
Elixir で IoT 開発、 Nerves なら簡単にできる!?
pojiro
1
150
Featured
See All Featured
Git: the NoSQL Database
bkeepers
PRO
430
65k
Stop Working from a Prison Cell
hatefulcrawdad
270
20k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
31
1.2k
Building Applications with DynamoDB
mza
95
6.5k
Into the Great Unknown - MozCon
thekraken
39
1.9k
Embracing the Ebb and Flow
colly
86
4.7k
KATA
mclloyd
29
14k
Practical Orchestrator
shlominoach
188
11k
Making the Leap to Tech Lead
cromwellryan
134
9.3k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
29
2.7k
Six Lessons from altMBA
skipperchong
28
3.8k
Rebuilding a faster, lazier Slack
samanthasiow
81
9k
Transcript
# Getting started with WP-CLI # WP-Athens 2016 Yoav Farhi
@yoavf
The original presentation was a live demo The
following slides are just a recap of the commands presented.
# WP-CLI website ‣ open http://wp-cli.org
# Download ‣ curl -O https://raw.githubusercontent.com/ wp-cli/builds/gh-pages/phar/wp-cli.phar
# Mac Setup ‣ chmod +x wp-cli.phar ‣ sudo mv
wp-cli.phar /usr/local/bin/wp
# Test & list of commands ‣ wp
# Download WordPress ‣ wp core download
# wp-config.php creation ‣ wp core config --dbname=wpcli --dbuser=root
--dbpass=root --dbhost=localhost --dbprefix=wpcli_
# Install ‣ wp core install --url="http://wpcli.dev" --title="WP-CLI
Demo" --admin_user=yoav --admin_password=mypassword
[email protected]
# Languages ‣ wp core language install el --activate ‣
wp core language activate en_US
# Updates ‣ wp core update
# Packages ‣ wp package ‣ wp package list ‣
wp package install aaemnnosttv/wp-cli-http-command
# Import ‣ wp plugin install wordpress-importer --activate ‣
wp http get https://wpcom-themes.svn.automattic.com/ demo/theme-unit-test-data.xml --scheme=https > theme-unit-test-data.xml ‣ wp import theme-unit-test-data.xml --authors=create
# Options ‣ wp option ‣ wp option update blogname
"WordCamp Athens wp-cli demo"
# Sticky posts option ‣ wp option get sticky_posts ‣
wp option update sticky_posts [] --format=json
# Post ‣ wp post ‣ wp post generate --count=2
# Post with external data ‣ wp http get http://loripsum.net/api/5
| wp post generate --post_content --count=1
# Search & replace ‣ wp search-replace Lorem WordPress
# Scaffolding ‣ wp scaffold child-theme my-new-theme --parent_theme=twentysixteen
--author_uri=http://yoav.fr --activate ‣ wp scaffold _s iloveathens --theme_name="I love Athens!" --author="Yoav Farhi" --sassify
# Themes ‣ wp theme list ‣ wp theme activate
twentyfourteen
# Plugins ‣ wp plugin list ‣ wp plugin install
jetpack --activate
# Subcommands from plugins ‣ wp jetpack ‣ wp jetpack
module list
# Export / DB ‣ wp export ‣ wp db
export l33t-backup.sql
# Multisite ‣ wp core multisite-convert ‣ wp site create
--slug=new-site ‣ wp theme activate twentyfourteen --url=http://wpcli.dev/new-site
Thanks Yoav Farhi @yoavf