Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions plugins/module_generator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,16 @@ put that corporate copyright notice (or maybe a copyleft notice, if that's your
***************************/
```

### Test Defines

You can specify the "#ifdef TEST" at the top of the test files with a custom define.
This example will put a "#ifdef CEEDLING_TEST" at the top of the test files.

```
:module_generator:
:test_define: CEEDLING_TEST
```

### Naming Convention

Finally, you can force a particular naming convention. Even if someone calls the generator
Expand All @@ -106,3 +116,4 @@ Your options are as follows:
- `:snake` - snake_case_is_all_lower_and_uses_underscores
- `:caps` - CAPS_FEELS_LIKE_YOU_ARE_SCREAMING


1 change: 1 addition & 0 deletions plugins/module_generator/lib/module_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ def divine_options(optz={})
:naming => ((defined? MODULE_GENERATOR_NAMING ) ? MODULE_GENERATOR_NAMING : nil ),
:update_svn => ((defined? MODULE_GENERATOR_UPDATE_SVN ) ? MODULE_GENERATOR_UPDATE_SVN : false ),
:skeleton_path=> ((defined? MODULE_GENERATOR_SOURCE_ROOT ) ? MODULE_GENERATOR_SOURCE_ROOT.gsub('\\', '/').sub(/^\//, '').sub(/\/$/, '') : "src" ),
:test_define => ((defined? MODULE_GENERATOR_TEST_DEFINE ) ? MODULE_GENERATOR_TEST_DEFINE : "TEST" ),
}

# Read Boilerplate template file.
Expand Down