# Rails plugin generator

**URL:** https://meta.discourse.org/t/rails-plugin-generator/95907
**Category:** Announcements
**Created:** [August 29, 2018, 11:43am UTC](https://meta.discourse.org/t/rails-plugin-generator/95907 "2018-08-29T11:43:01Z")
**Posts on this page:** 1
**Showing post:** 14

<div class="post-metadata">

### Author: ![angus](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/angus/32/341715_2.png) [@angus](https://meta.discourse.org/u/angus)
#### Post date: [August 30, 2018, 11:51am UTC](https://meta.discourse.org/t/rails-plugin-generator/95907/14 "2018-08-30T11:51:49Z")

</div>

I was just testing a theory about the origin of [an issue](https://meta.discourse.org/t/question-answer-plugin/56032/141) in the elections and qa plugins, and needed to test some logic in isolation. Normally I would create a new plugin by hand to do this, but this time it was much easier using the plugin generator, just a single command. Useful already 🙂 Thanks.

I was getting a NameError though on initial load after generating a plugin (I had removed `tmp`). The plugin.rb includes an auto-generated `enabled_site_setting` out of the box, but the setting isn’t defined in `config/settings.yml`. If you add the setting, the error goes away. We’ll need to either remove the auto-generated enabled setting or add a config/settings.yml with the auto-generated enabled setting included by default.

---

_[View the full topic](https://meta.discourse.org/t/rails-plugin-generator/95907)._
