16
JAKARTA WORDPRESS MEETUP #9 Local WordPress Development With VVV

Jakarta WordPress Meetup #9: Introducing VVV 2

Embed Size (px)

Citation preview

Page 1: Jakarta WordPress Meetup #9: Introducing VVV 2

JAKARTA WORDPRESS MEETUP #9Local WordPress Development With VVV

Page 2: Jakarta WordPress Meetup #9: Introducing VVV 2

WHO AM I?

My Name is Ivan Kristianto

Jakarta WordPress Meetup Organizer

WordPress Core Contributor

WordPress Plugin Author and Contributor

WordCamp Organizer

Page 3: Jakarta WordPress Meetup #9: Introducing VVV 2

BEFORE WE START

Please visit our website: https://wp-id.org

Please join our Facebook group:https://www.facebook.com/groups/WordPressDevID/

Please join our Slack:https://chat.wp-id.org

Page 4: Jakarta WordPress Meetup #9: Introducing VVV 2
Page 5: Jakarta WordPress Meetup #9: Introducing VVV 2

OK, LET’S START

Page 6: Jakarta WordPress Meetup #9: Introducing VVV 2

VVV 2 JUST RELEASED!

Page 7: Jakarta WordPress Meetup #9: Introducing VVV 2

WHY USE VVV?

The XAMPP or MAMP? It’s limited and complex setup for WordPress development.

Ready out of the box, customized and built for WordPress development

It has everything You need for WordPress Development

A recommended setup for WordPress Developer and for WordPress VIP.

Page 8: Jakarta WordPress Meetup #9: Introducing VVV 2

WHAT IS INCLUDED?

Nginx: The Web Server

MariaDB 10.1.x (drop-in replacement for MySQL): Database Server

php-fpm 7.0.x: Well You know it, to run PHP

WP-CLI: WordPress Command Line Tools

Memcached: Memory Caching System

PHPUnit: To Unit Test your code

Composer: Dependency Manager for PHP

NodeJs: Server-side Javascript environment

Mailcatcher: Catch mail and servers

Page 9: Jakarta WordPress Meetup #9: Introducing VVV 2

SETTING UP VVV

1. Download & Install VirtualBox and Vagrant

2. Install vagrant host updater: vagrant plugin install vagrant-hostsupdater

3.Install vagrant triggers: vagrant plugin install vagrant-triggers

4. Clone VVV: git clone git://github.com/Varying-Vagrant-Vagrants/VVV.git vvv

5. Startup VVV: vagrant up

6. Get a cup of coffee, and listen to your favorite music! It will take a while to finish.

Page 10: Jakarta WordPress Meetup #9: Introducing VVV 2
Page 11: Jakarta WordPress Meetup #9: Introducing VVV 2

SETTING A NEW SITE

I recommend to setup a new site for each project You work, for example: localdomain.dev

Setting up a new site is “tricky” at this time. We need a workaround a little

I recommend to use: Variable VVV ( https://github.com/bradp/vv )

Let’s create a new site.

Page 12: Jakarta WordPress Meetup #9: Introducing VVV 2

WP-CLI IS THE BEST

WP-CLI is ready out of the box

It take sometime to learn, but when You know it, It is faster for development

To use WP-CLI:vagrant ssh cd /srv/www/<yoursite>/htdocs wp —version

Checkout WP-CLI available command: http://wp-cli.org/commands/

Page 13: Jakarta WordPress Meetup #9: Introducing VVV 2

DEBUGGING WITH XDEBUG

Still using var_dump to debug your code? Let’s take debugging to another level!

Debugging in WordPress is never been easier using XDebug

You can trace your code execution and do profiling as well

Setup your XDebug with PHPStorm

How to setup click here

Demo

Page 14: Jakarta WordPress Meetup #9: Introducing VVV 2

CATCH EMAIL WITH MAILCATCHER

Most of the time your website will send email. And to debug it from your local env, you need to catch those emails. This is what Mailcatcher for.

Go to: http://vvv.dev:1080

Just try to send any email, and You will see it will catch there.

Demo

Page 15: Jakarta WordPress Meetup #9: Introducing VVV 2

MORE VVV INSTALLED PACKAGES

Git

Subversion

Phpmyadmin

Memcached

Webgrind

Grunt-CLI

PhpMemcachedAdmin

Etc..

Page 16: Jakarta WordPress Meetup #9: Introducing VVV 2

–Ivan Kristianto

“Happy VVV!”