For Developers

How Does 'module.config' Work?

The module.config file is just a set of instructions that tells Beaver Brewer a bit more about your module. You do not need to include a module.config file with your module in order for it to achieve basic compatibility with Beaver Brewer, but you do need to include it if you want to achieve full compatibility and enable automatic (one-click) updates through the Beaver Brewer admin page. But don't worry! It's simple!

The Anatomy of a module.config File

Here's a sample module.config file, taken straight from the Beaver Brewer Module Boilerplate:

# Module.config
# For more info on how to use this file, visit https://beaverbrewer.com/module-config

Module Name: Boilerplate
Module Version: 1.2
Author Name: Ryan Benhase
Author URL: http://beaverbrewer.com
Short Description: This is a boilerplate module that is meant to be edited.
Update URL: http://beaverbrewer.com/bb-updates/beaver-brewer-module-boilerplate
Download ZIP: http://beaverbrewer.com/bb-downloads/beaver-brewer-module-boilerplate
More Info URL: http://beaverbrewer.com/module-boilerplate

That's it! By including this information with your module, you can enable one-click updates and make your module listing look more attractive on the Beaver Brewer admin page. To break it down:

Module Name: The (human-readable) name of your module.

Module Version: The current version of your module. Increment this each time you want to release an update.

Author Name: Presumably you (or your team/organization).

Author URL: The URL to a website/webpage for you/your organization.

Short Description: A sentence or two about your module which appears in the Beaver Brewer admin. This should be 140 characters or less.

Update URL: The URL of the remote module.config file that you want to use to check for updates; Beaver Brewer will parse out the update version information it needs from this file. Supplying a raw link to the module.config file inside your module's BitBucket or GitHub repository works great, but you can also create your own update server if desired.

Download ZIP: The download URL for the ZIP file containing the latest version of your module. Once again, BitBucket and GitHub work well. This must be a direct link to a ZIP file, however (and not a link to a web page).

More Info URL: A URL to a web page that will provide more information about your module.

 

One Additional Line You Can Include

The example above contains all the information you should supply for a free Beaver Brewer module, but if you want to charge users to download your module, you will also need to include the "Purchase URL" line. Otherwise, leave it out.

Purchase URL: A URL to a web page that will allow users to purchase your module. Only use this if your module is going to be a "paid" module.

 

What to Do With the File

Simply place your module.config file inside your main (top-level) module folder. If you want to enable automatic update notifications and one-click updates for your module, you'll also need to ensure a few other things.