Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.
A Git Friendly Way to
Handle WP Updates
Hi!
Per André Rønsen, CTO & partner
Foad Yousefi, Developer
Twitter:
@perandre
@frontkom
TL;DW
We built a tool to fetch specific
versions of core, plugins &
themes using a single config file
Better security!
Cleaner repo!
Happy developers!
Some background
Two ways to maintain your WP code
FTP :)
Stuff that happen when
you update a plugin
directly on production
server
Now, imagine auto
update doing this every
other day ...
We want Git.
We want to auto
update (some) plugins
WP Auto Updates has
some config for
versions ++
… but no config for a
Perfect Git Setup™
Plugins to the rescue?
Lets you select which plugins to auto update
(but has no Git support).
How do other CMS-es
solve it?
Drupal: custom plugins separated from contrib
(Raise of hands: How
many use Git?
Terminal? WP-CLI?
Build files?)
“WP-CLI is the
command-line
interface for
WordPress.”
Build file?
Website! Another website!
Build file: a file listing what themes and plugins to download. Version control 1 file – not 1 m...
Introducing: WP-
CLI Build
A command line tool
extending WP-CLI.
https://github.com/front/wp-cli-build
Install it!
~ wp package install
front/wp-cli-build
Get started!
~ wp build-generate
Latest patch within minor version 4.9
Latest available version
Fixed: Stick to this
Latest minor within major version 1
.gitignore: inverted
The old way
such files
very bloat!
not wow
The new way
~ wp build
</theory>
It’s demo time!
Step 1:
Log into server and put
your site into Git with
WP-CLI
Step 2:
Clone the site and run
the build file
Step 3:
Update plugins
Step 4:
Make the build file
run every day
~ crontab -e
Better security!
Cleaner repo!
Happy developers!
[wait for
applause]
THX!
Reach out:
perandre@front.no
twitter.com/perandre
The links!
● WP-CLI Build on Github
● WP-CLI.org
● Codex: Configuring Automatic Background Updates
● Scheduling tasks with...
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
A Git Friendly Way to Handle WordPress Updates –  WordCamp Oslo 2018
Nächste SlideShare
Wird geladen in …5
×

A Git Friendly Way to Handle WordPress Updates – WordCamp Oslo 2018

97 Aufrufe

Veröffentlicht am

TL;DR Frontkom built a tool to fetch specific versions of WordPress core, plugins & themes using a single JSON file. This enables us to combine auto updates with a slick Git setup.

Presented on WordCamp Oslo 2018 by Per Andre Rønsen and Foad Yousefi.

Veröffentlicht in: Software
  • Als Erste(r) kommentieren

  • Gehören Sie zu den Ersten, denen das gefällt!

A Git Friendly Way to Handle WordPress Updates – WordCamp Oslo 2018

  1. 1. A Git Friendly Way to Handle WP Updates
  2. 2. Hi! Per André Rønsen, CTO & partner Foad Yousefi, Developer
  3. 3. Twitter: @perandre @frontkom
  4. 4. TL;DW We built a tool to fetch specific versions of core, plugins & themes using a single config file
  5. 5. Better security! Cleaner repo! Happy developers!
  6. 6. Some background
  7. 7. Two ways to maintain your WP code FTP :)
  8. 8. Stuff that happen when you update a plugin directly on production server
  9. 9. Now, imagine auto update doing this every other day ...
  10. 10. We want Git. We want to auto update (some) plugins
  11. 11. WP Auto Updates has some config for versions ++
  12. 12. … but no config for a Perfect Git Setup™
  13. 13. Plugins to the rescue?
  14. 14. Lets you select which plugins to auto update (but has no Git support).
  15. 15. How do other CMS-es solve it?
  16. 16. Drupal: custom plugins separated from contrib
  17. 17. (Raise of hands: How many use Git? Terminal? WP-CLI? Build files?)
  18. 18. “WP-CLI is the command-line interface for WordPress.”
  19. 19. Build file?
  20. 20. Website! Another website! Build file: a file listing what themes and plugins to download. Version control 1 file – not 1 million.
  21. 21. Introducing: WP- CLI Build
  22. 22. A command line tool extending WP-CLI.
  23. 23. https://github.com/front/wp-cli-build
  24. 24. Install it!
  25. 25. ~ wp package install front/wp-cli-build
  26. 26. Get started!
  27. 27. ~ wp build-generate
  28. 28. Latest patch within minor version 4.9 Latest available version Fixed: Stick to this Latest minor within major version 1
  29. 29. .gitignore: inverted
  30. 30. The old way such files very bloat! not wow
  31. 31. The new way
  32. 32. ~ wp build
  33. 33. </theory> It’s demo time!
  34. 34. Step 1: Log into server and put your site into Git with WP-CLI
  35. 35. Step 2: Clone the site and run the build file
  36. 36. Step 3: Update plugins
  37. 37. Step 4: Make the build file run every day
  38. 38. ~ crontab -e
  39. 39. Better security! Cleaner repo! Happy developers!
  40. 40. [wait for applause]
  41. 41. THX!
  42. 42. Reach out: perandre@front.no twitter.com/perandre
  43. 43. The links! ● WP-CLI Build on Github ● WP-CLI.org ● Codex: Configuring Automatic Background Updates ● Scheduling tasks with cron jobs ● drush.org ● frontkom.no

×