A WordPress site for travel and food after the sun sets.
-
Install PHP 7.4, Composer, and MySQL to your system first.
-
Run the background service of MySQL.
brew services start mysql
- Run the MySQL prompt.
mysql -u root
- Create the database for WordPress.
CREATE DATABASE aroundafterdark;
- Check if your database was successfully created.
SHOW DATABASES;
- Go to the theme folder
wp-content/themes/after-dark
and install the theme dependencies. You can view the list of dependencies inpackage.json
located in the theme's folder.
npm install
- Run Sass to automate compiling of the theme's style.
npm run sass
- Run Parcel to automate rebuilding of the theme's JavaScript files.
npm run watch
- Run the PHP server.
php -S localhost:8000
- Install PHP_CodeSniffer using Composer.
composer global require "squizlabs/php_codesniffer=*"
- Install the PHP_CodeSniffer Composer Installer along with the WordPress Coding Standard.
composer global require wp-coding-standards/wpcs dealerdirect/phpcodesniffer-composer-installer
- Check if the WordPress Coding Standard was added to PHP_CodeSniffer. ``.
phpcs -i
-
Setup WordPress database by going to
localhost:8000
on your browser. Follow the instructions carefully. -
You can check your codes if they follow WordPress Coding Conventions.
phpcs --standard=WordPress path/to/file
- Don't forget to compress the JavaScript files before you push any changes to the remote repository.
npm run build
This page is published under GNU General Public License