Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Speaker Deck
PRO
Sign in
Sign up for free
Yoav Farhi - Getting started with WP-CLI - WordCamp Athens 2016
WordPress Greek Community
November 19, 2016
Programming
1
190
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
Είμαι Freelancer, πώς να κάνω personal branding
wpgr
0
11
WooCommerce 5+5 must have plugins
wpgr
0
64
Git: βασικές έννοιες και λειτουργίες
wpgr
0
17
Creating a custom WooCommerce plugin
wpgr
0
81
Η τέλεια στρατηγική προώθησης ενός WordPress/Woo website - Γιάννης Δεβελέκος
wpgr
0
140
Cookies και άλλες τεχνολογίες στην ιστοσελίδα μου: Τελικά τι μπορώ να χρησιμοποιώ; - Βασίλης Καρκατζούνης
wpgr
0
53
Making the most of WooCommerce - Δημήτριος Σελημίδης
wpgr
0
27
Making WordPress faster and greener - David Hilditch [ΕΝ]
wpgr
0
42
It is not a sprint is a marathon… running your eshop - Ιωάννης Καστορίνης
wpgr
0
22
Other Decks in Programming
See All in Programming
OSSから学んだPR Descriptionの書き方
fugakkbn
4
130
Step Functions Distributed Map を使ってみた
codemountains
0
100
CDKでValidationする本当の方法 / cdk-validation
gotok365
1
200
Refactor with using `available` and `deprecated`
417_72ki
3
380
jq at the Shortcuts
cockscomb
1
410
PHPDocにおける配列の型定義を少し知る
shimabox
1
130
Writing Greener Java Applications
hollycummins
0
340
Remix + Cloudflare Pages + D1 で ポケモン SV のレンタルチームを検索できるアプリを作ってみた
kuroppe1819
4
1.3k
まだ日本国内で利用できないAppActionsにトライしてみた / MoT TechTalk #15
mot_techtalk
0
110
はてなリモートインターンシップ2022 Web API 講義資料
hatena
0
150
ECS Service Connectでマイクロサービスを繋いでみた
xblood
0
530
あなたと 「|」 したい・・・
track3jyo
PRO
2
1k
Featured
See All Featured
How GitHub Uses GitHub to Build GitHub
holman
465
280k
Music & Morning Musume
bryan
37
4.6k
Visualization
eitanlees
128
12k
Docker and Python
trallard
30
1.9k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
236
1.1M
Happy Clients
brianwarren
90
5.8k
Code Review Best Practice
trishagee
50
11k
Designing on Purpose - Digital PM Summit 2013
jponch
108
5.9k
Why Our Code Smells
bkeepers
PRO
326
55k
RailsConf & Balkan Ruby 2019: The Past, Present, and Future of Rails at GitHub
eileencodes
120
29k
Agile that works and the tools we love
rasmusluckow
320
20k
Build your cross-platform service in a week with App Engine
jlugia
221
17k
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