Skip to content

Composer setup to separate Wordpress core files from themes and plugins.

Notifications You must be signed in to change notification settings

jeremymouton/wordpress-composer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Wordpress-composer

Composer setup to separate Wordpress core files from themes and plugins.
Moves Wordpress core to a separate folder (/wp/ by default).

Installation

1. Configure custom paths

wp-config.php
  • Duplicate sample.wp-config.php to wp-config.php
  • Edit WP_SITE_PATH with site path (i.e http://localhost/PATH_TO_SITE, no trailing slash)
  • Configure database settings
  • Replace salt (secret-key service)
.htaccess
  • Duplicate sample.htaccess to .htaccess
  • If accessing site via http://localhost/:
    Uncomment RewriteBase and edit PATH_TO_SITE (same as PATH_TO_SITE in wp-config.php, but without http://localhost/ and with trailing slash).

2. Add wp-content files

Copy theme and plugin folders to /wp-content/themes/ and /wp-content/plugins/.

3. Install Wordpress

Run ~$ composer install to install Wordpress to the /wp/ folder.

4. Activate theme

If not already activated, login to the Wordpress admin (http://localhost/PATH_TO_SITE/wp-admin/). From the sidebar go to Appearance > Themes, and activate the theme.


Modifying installation path

By default, Wordpress core will be installed inside /wp/. To modify the install path, you'll need to edit a few paths.


Development notes

  • Theme and plugins inside /wp-content/.
  • Whitelist plugins and themes in .gitignore.

About

Composer setup to separate Wordpress core files from themes and plugins.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages