1.0.7 • Published 9 years ago

ember-hostname-environment v1.0.7

Weekly downloads
8
License
MIT
Repository
github
Last release
9 years ago

Ember Hostname Environment

Manipulate ember-cli ENV as you like by creating a node module by the name config/environment-{hostname}.js

Note: This is not a standard ember-addon

Installation

  • npm install ember-hostname-environment --save-dev

Usage

  • Create a module with the name config/environment-{computer-name}.js of the form:
//config/environment-my-computer-name.js
module.exports = function(ENV){
	//Here you can manipulate the ENV object as you like
	//Note that you can use ENV.environment ( can be 'development' || 'production' || 'test')

	//Of course, eventually, you HAVE TO RETURN ENV!!!
	return ENV; 
}
  • In config/environment.js add the following:
var emberHostnameEnvironment = require('ember-hostname-environment');

module.exports = function(environment) {
  	var ENV = {
		// ...
		// ...
		// ...
	};

	//..
	//..
	//..

 	return emberHostnameEnvironment(ENV);
};

License

MIT

1.0.7

9 years ago

1.0.6

9 years ago

1.0.5

9 years ago

1.0.4

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago