DevinVinson / WordPress-Plugin-Boilerplate

[WordPress] A foundation for WordPress Plugin Development that aims to provide a clear and consistent guide for building your plugins.
http://wppb.io
7.67k stars 2.25k forks source link

Boilerplate generator #130

Closed pablopaul closed 10 years ago

pablopaul commented 10 years ago

Hi,

somewhere I read that you guys plan to offer a "boilerplate generator" likely to that one from http://underscores.me

I think this is a really good idea since the plugin development setup time could be really decreased… You know what I mean (let us automate the simple tasks :)).

I searched for a public repo for the underscores.me page but could not find any, do you have a clue where to get their code as a starting point for the Boilerplate generator?

One more thing @tommcfarlin : Please link to the official WordPress Plugin Boilerplate in the GitHub repo description and the readme file.

Best, Pablo

bradvin commented 10 years ago

This is something that I would love to help out with.

I found this Yeoman generator that uses the boilerplate code, and seems to be kept up to date : https://github.com/romainberger/yeoman-wordpress (via @romainberger)

Before I found that, I also started a grunt-init version with the same concept but it is not complete - https://github.com/fooplugins/grunt-wp-boilerplate (Not sure if this is worth while finishing though, as Yeoman seems to be the new replacement for grunt-init)

Whatever we decide to do, we must make it as easy as possible to keep the templates used by the generator up to date with the latest boilerplate release. I am not sure what the best approach would be, but ideally I would want to make minimal or no changes to the source files. When building the grunt-init generator above, having to go through all files to find and replace "plugin-name" with {%= name %} was the actual time waster, although this can probably be automated with a tool...

romainberger commented 10 years ago

Hi, My wordpress generator indeed uses this boilerplate. It is relatively kept up to date, by that I mean I fix bugs when needed, but I stopped using Yeoman for Wordpress development so I don't add any features or improve it anymore.

If any of you want to create a generator running on node / grunt or yeoman it could be interesting to make a module that could be used as a dependency in generators (although Yeoman is very opinionated so I don't know if it would be easy). There are others generators made for wordpress that could probably benefit from this (like Yeopress).

tommcfarlin commented 10 years ago

@pablopaul I'm assigning this to 2.7.0 to make sure the README is updated in the next version of the boilerplate.

@bradvin:

This is something that I would love to help out with.

Chat with @AlexMansfield via Twitter. He and I are currently coordinating an effort to get this all setup within the next couple of versions of the Boilerplate. I'll be sure to add you to the repository once I scope the site, and be sure to include you on future emails about this!

pablopaul commented 10 years ago

I found the original ticket for the generator which also contains a link to the underscores generator script: https://github.com/tommcfarlin/WordPress-Plugin-Boilerplate/issues/118 https://github.com/Automattic/underscores.me/blob/master/plugins/underscoresme-generator/underscoresme-generator.php

This makes this ticket more or less obsolete, I will open a new one for the README update task, please assign this again to 2.7.0 @tommcfarlin and sorry for the little mess ;)