Skip to content

Environment-specific loading for 'model-config' - #141

Closed
dashby3000 wants to merge 2 commits into
strongloop:masterfrom
dashby3000:master
Closed

dashby3000 wants to merge 2 commits into
strongloop:masterfrom
dashby3000:master

Conversation

@dashby3000

Copy link
Copy Markdown

Added code to allow model-config to respect model-config.local.js and model-config.env.js as do other config files.

… model-config.env.js as do other config files.
@raymondfeng

Copy link
Copy Markdown
Member

Good idea

@raymondfeng

Copy link
Copy Markdown
Member

@dashby3000 There is a style issue that fails the build.

Missing space after line comment at ./lib/config-loader.js :
    33 |ConfigLoader.loadModels = function(rootDir, env) {
    34 |  /*jshint unused:false */
    35 |  //return tryReadJsonConfig(rootDir, 'model-config') || {};
----------^
    36 |  return loadNamed(rootDir, env, 'model-config', mergeModelConfig);
    37 |};

Can you fix it?

A test is also appreciated to cover your enhancement.

@dashby3000

Copy link
Copy Markdown
Author

Updated to fix the styling issue. As for the test, I will just duplicate the tests that already exits for checking the merge.

@raymondfeng

Copy link
Copy Markdown
Member

Closed by #143

raymondfeng added a commit that referenced this pull request Aug 3, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants