A Yeoman generator based on the famous Wordpress-Plugin-Boilerplate for quickly starting a new wordpress plugin.
If you're using Ubuntu or a similar Debian based Linux distro, these are pretty easy to install as shown below.
# install npm
sudo apt-get install npm
# install yeoman for npm to use
sudo npm install -g yo
To install this generator for use with the yo
command, use the following command:
sudo npm install -g generator-wpplug
Open a terminal and cd to the directory you'd like your soon-to-be plugin to be created in. This is usually the wordpress plugin directory, but you could also do everything on your own computer and move it to wordpress server later.
# cd into the wordpress plugin directory
cd wp-content/plugins
Now use the yo
command to create the template for your new plugin.
# Run the generator
yo wpplug