Skip to content
This repository has been archived by the owner on Jun 1, 2020. It is now read-only.

audioverse-org/wp-avorg-dev

Repository files navigation

wp-avorg-dev

Installation

Install Docker, then:

chmod +x *.sh
docker-compose up
./setup.sh
open http://localhost:8000

Usage

docker-compose up
open http://localhost:8000
URL Description
http://localhost:8000 Home
http://localhost:8000/wp-login.php Admin Login
http://localhost:8001 Webgrind

Local Database

Key Value
Host localhost
Port 3308
User wordpress
Password wordpress
Database wordpress

Transpiling

Sass

npm install -g sass
sass wp-avorg-plugin/style/style.scss wp-avorg-plugin/style/style.css

If you use an IDE like PhpStorm you can set up a file watcher to do this automatically.

More information

Webpack + TypeScript

docker-compose run webpack npm run build

Commands

Host

Command Description
docker-compose build --pull --no-cache Force image updates; update WordPress
docker exec wp-avorg-dev_wordpress_1 /bin/bash -c 'cd /usr/src/wordpress && ls' Run command from outside container
docker exec -it wp-avorg-dev_wordpress_1 bash Jump into machine

CLI

Command Description
./wp.sh Jump into WordPress container
./wp.sh plugin list List installed plugins

Container

Command Description
ctrl+p+q or exit Jump out of machine
prentenv See all env vars, including Docker's

Configuring Xdebug

Disable the following options in preferences:

  • Force break at first line when no path mapping specified
  • Force break at first line when a script is outside the project

Validate your installation of Xdebug. You should see something like this:

Xdebug validation

In Preferences > Languages & Frameworks > PHP > Servers, turn on the following setting for localhost:

Use path mappings (select if the server is remote or symlinks are used)

Then set the server path for wp-avorg-dev/wp-avorg-plugin to the following path:

/var/www/html/wp-content/plugins/wp-avorg-plugin

Install the Xdebug helper Chrome extension, enable debug mode, and tell PhpStorm to start listening for connections. Then you're ready to start adding breakpoints and debugging your code.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •