Use the override the package.name with the jam.name if provided. #102

Merged
merged 1 commit into from Dec 14, 2012
Jump to file or symbol
Failed to load files and symbols.
+9 −1
Split
View
@@ -173,6 +173,9 @@ exports.updateRequireConfig = function (package_dir, baseurl, callback) {
if (main) {
val.main = main;
}
+ if (cfg.jam && cfg.jam.name) {
+ val.name = cfg.jam.name;
+ }
packages.push(val);
if (cfg.shim) {
shims[cfg.name] = cfg.shim;
View
@@ -11,6 +11,11 @@ exports.load = async.memoize(function (dir, callback) {
callback(err);
}
try {
+ // if there is a jam.name we must override the
+ // package name early.
+ if (settings.jam && settings.jam.name) {
+ settings.name = settings.jam.name;
+ }
exports.validate(settings, settings_file);
}
catch (e) {
View
@@ -1,6 +1,6 @@
{
"name": "jamjs",
- "version": "0.2.11",
+ "version": "0.2.12",
"description": "",
"maintainers": [
{"name": "Caolan McMahon", "web": "https://github.com/caolan"}