I had a great time speaking at WordCamp Norrkoping on August 28th in Sweden. It was a pleasure to talk with such an engaged crowd and I really enjoyed sharing my views on working as a team.
During my talk I gave a demo on how to create a base install of WordPress using composer. Here’s the gist of my composer.json file. I’m happy to discuss and hear any feedback you may have. Stay tuned for pictures, additional resources and a link to my presentation deck.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "edmund.turbin/wordpress-starter", | |
"description": "This is a basic wordpress install with some changes to the wp-content and core file locations", | |
"type": "dev", | |
"license": "GPL", | |
"authors": [ | |
{ | |
"name": "Edmund Turbin", | |
"email": "edmund.turbin@wpengine.com" | |
} | |
], | |
"repositories":[ | |
{ | |
"type": "composer", | |
"url": "http://wpackagist.org" | |
}, | |
{ | |
"type": "package", | |
"package": { | |
"name": "roots/sage", | |
"type": "wordpress-theme", | |
"version": "dev-master", | |
"source": { | |
"url":"https://github.com/roots/sage.git", | |
"type": "git", | |
"reference": "master" | |
} | |
} | |
} | |
], | |
"minimum-stability": "dev", | |
"require": { | |
"composer/installers": "~1.0", | |
"wpackagist-plugin/debug-bar":"*", | |
"wpackagist-plugin/debug-objects":"*", | |
"johnpbloch/wordpress": "*", | |
"roots/sage": "*" | |
}, | |
"extra": { | |
"wordpress-install-dir": "wp", | |
"installer-paths": { | |
"content/plugins/{$name}": ["type:wordpress-plugin"], | |
"content/themes/{$name}": ["type:wordpress-theme"], | |
"content/mu-plugins/{$name}": ["type:wordpress-muplugin"] | |
} | |
}, | |
"scripts": { | |
"post-install-cmd": [ | |
"cp wp/index.php ./index.php", | |
"cp wp/wp-config-sample.php wp/wp-config.php", | |
"sed -i '' \"s/\\/wp-blog-header/\\/wp\\/wp-blog-header/g\" index.php", | |
"sed -i '' '2i\\'$'\\n''/** Define variables for custom content directory */'$'\\n' wp/wp-config.php", | |
"sed -i '' '3i\\'$'\\n''define ('WP_CONTENT_FOLDERNAME', 'content');'$'\\n' wp/wp-config.php", | |
"sed -i '' '4i\\'$'\\n''define ('WP_CONTENT_DIR', ABSPATH . WP_CONTENT_FOLDERNAME);'$'\\n' wp/wp-config.php" | |
] | |
} | |
} |