From d41896c301cb796ce0a07cd06046c18a86b27bd5 Mon Sep 17 00:00:00 2001 From: Dwayne Charrington Date: Wed, 3 Aug 2016 08:18:42 +1000 Subject: [PATCH] chore(all): release 1.0.12 --- dist/amd/aurelia-configuration.d.ts | 41 +++++++++++++++++ ...{configure.js => aurelia-configuration.js} | 22 +++++++++- dist/amd/aurelia-configuration.js.map | 1 + dist/amd/configure.d.ts | 34 -------------- dist/amd/configure.js.map | 1 - dist/amd/index.d.ts | 3 -- dist/amd/index.js | 19 -------- dist/amd/index.js.map | 1 - dist/index.d.ts | 44 +++++++++++++++++-- 9 files changed, 103 insertions(+), 63 deletions(-) create mode 100644 dist/amd/aurelia-configuration.d.ts rename dist/amd/{configure.js => aurelia-configuration.js} (88%) create mode 100644 dist/amd/aurelia-configuration.js.map delete mode 100644 dist/amd/configure.d.ts delete mode 100644 dist/amd/configure.js.map delete mode 100644 dist/amd/index.d.ts delete mode 100644 dist/amd/index.js delete mode 100644 dist/amd/index.js.map diff --git a/dist/amd/aurelia-configuration.d.ts b/dist/amd/aurelia-configuration.d.ts new file mode 100644 index 0000000..efb1bc8 --- /dev/null +++ b/dist/amd/aurelia-configuration.d.ts @@ -0,0 +1,41 @@ +declare module "configure" { + import { Loader } from 'aurelia-loader'; + export interface ConfigInterface { + } + export class Configure { + loader: Loader; + environment: string; + environments: any; + directory: string; + config_file: string; + cascade_mode: boolean; + private _config_object; + private _config_merge_object; + constructor(loader: Loader); + setDirectory(path: any): void; + setConfig(name: any): void; + setEnvironment(environment: any): void; + setEnvironments(environments?: boolean): void; + setCascadeMode(bool?: boolean): void; + readonly obj: ConfigInterface; + readonly config: string; + is(environment: any): boolean; + check(): void; + environmentEnabled(): boolean; + environmentExists(): boolean; + get(key: any, defaultValue?: any): any; + set(key: any, val: any): void; + merge(obj: any): void; + lazyMerge(obj: any): void; + setAll(obj: any): void; + getAll(): ConfigInterface; + loadConfig(): Promise; + loadConfigFile(path: any, action: any): Promise; + mergeConfigFile(path: any): Promise; + } +} +declare module "index" { + import { Configure } from "configure"; + export function configure(aurelia: any, configCallback: any): Promise<{}>; + export { Configure }; +} diff --git a/dist/amd/configure.js b/dist/amd/aurelia-configuration.js similarity index 88% rename from dist/amd/configure.js rename to dist/amd/aurelia-configuration.js index 6b29243..6c1a45a 100644 --- a/dist/amd/configure.js +++ b/dist/amd/aurelia-configuration.js @@ -7,7 +7,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, var __metadata = (this && this.__metadata) || function (k, v) { if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); }; -define(["require", "exports", 'aurelia-dependency-injection', 'aurelia-path', 'aurelia-loader', 'deep-extend'], function (require, exports, aurelia_dependency_injection_1, aurelia_path_1, aurelia_loader_1, deep_extend_1) { +define("configure", ["require", "exports", 'aurelia-dependency-injection', 'aurelia-path', 'aurelia-loader', 'deep-extend'], function (require, exports, aurelia_dependency_injection_1, aurelia_path_1, aurelia_loader_1, deep_extend_1) { "use strict"; var Configure = (function () { function Configure(loader) { @@ -184,4 +184,22 @@ define(["require", "exports", 'aurelia-dependency-injection', 'aurelia-path', 'a }()); exports.Configure = Configure; }); -//# sourceMappingURL=configure.js.map \ No newline at end of file +define("index", ["require", "exports", "configure"], function (require, exports, configure_1) { + "use strict"; + exports.Configure = configure_1.Configure; + function configure(aurelia, configCallback) { + var instance = aurelia.container.get(configure_1.Configure); + if (configCallback !== undefined && typeof (configCallback) === 'function') { + configCallback(instance); + } + return new Promise(function (resolve, reject) { + instance.loadConfig() + .then(function () { return resolve(); }) + .catch(function () { + reject(new Error('Configuration file could not be loaded')); + }); + }); + } + exports.configure = configure; +}); +//# sourceMappingURL=aurelia-configuration.js.map \ No newline at end of file diff --git a/dist/amd/aurelia-configuration.js.map b/dist/amd/aurelia-configuration.js.map new file mode 100644 index 0000000..fea8482 --- /dev/null +++ b/dist/amd/aurelia-configuration.js.map @@ -0,0 +1 @@ +{"version":3,"file":"aurelia-configuration.js","sourceRoot":"","sources":["../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AC;YACxE,cAAc,CAAC,QAAQ,CAAC,CAAC;QAC7B,CAAC;QAED,MAAM,CAAC,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;YAC/B,QAAQ,CAAC,UAAU,EAAE;iBAChB,IAAI,CAAC,cAAM,OAAA,OAAO,EAAE,EAAT,CAAS,CAAC;iBACrB,KAAK,CAAC;gBACH,MAAM,CAAC,IAAI,KAAK,CAAC,wCAAwC,CAAC,CAAC,CAAC;YAChE,CAAC,CAAC,CAAC;QACX,CAAC,CAAC,CAAC;IACP,CAAC;IAfe,iBAAS,YAexB,CAAA;IAEkB"} \ No newline at end of file diff --git a/dist/amd/configure.d.ts b/dist/amd/configure.d.ts deleted file mode 100644 index 71fc920..0000000 --- a/dist/amd/configure.d.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { Loader } from 'aurelia-loader'; -export interface ConfigInterface { -} -export declare class Configure { - loader: Loader; - environment: string; - environments: any; - directory: string; - config_file: string; - cascade_mode: boolean; - private _config_object; - private _config_merge_object; - constructor(loader: Loader); - setDirectory(path: any): void; - setConfig(name: any): void; - setEnvironment(environment: any): void; - setEnvironments(environments?: boolean): void; - setCascadeMode(bool?: boolean): void; - readonly obj: ConfigInterface; - readonly config: string; - is(environment: any): boolean; - check(): void; - environmentEnabled(): boolean; - environmentExists(): boolean; - get(key: any, defaultValue?: any): any; - set(key: any, val: any): void; - merge(obj: any): void; - lazyMerge(obj: any): void; - setAll(obj: any): void; - getAll(): ConfigInterface; - loadConfig(): Promise; - loadConfigFile(path: any, action: any): Promise; - mergeConfigFile(path: any): Promise; -} diff --git a/dist/amd/configure.js.map b/dist/amd/configure.js.map deleted file mode 100644 index 92cb7e1..0000000 --- a/dist/amd/configure.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"configure.js","sourceRoot":"","sources":["../../src/configure.ts"],"names":[],"mappings":";;;;;;;;;;;IAUA;QAYI,mBAAY,MAAc;YAT1B,gBAAW,GAAW,SAAS,CAAC;YAEhC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,KAAI,CAAC,oBAAoB,GAAG,IAAI,CAAC;gBACrC,CAAC;YACL,CAAC,CAAC,CAAC;QACX,CAAC;QASD,kCAAc,GAAd,UAAe,IAAI,EAAE,MAAM;YACvB,IAAI,WAAW,GAAG,IAAI,CAAC,QAAQ,EAAE,CAAC;YAElC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,WAAW,CAAC;iBACnC,IAAI,CAAC,UAAA,IAAI;gBACN,EAAE,CAAC,CAAC,OAAO,IAAI,KAAK,QAAQ,CAAC,CAAC,CAAC;oBAC3B,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;gBAC5B,CAAC;gBACD,MAAM,CAAC,IAAI,CAAC,CAAC;YACjB,CAAC,CAAC;iBACD,KAAK,CAAC;gBACH,OAAO,CAAC,KAAK,CAAC,sDAAoD,WAAa,CAAC,CAAC;YACrF,CAAC,CAAC,CAAC;QACX,CAAC;QAYD,mCAAe,GAAf,UAAgB,IAAI;YAApB,iBAEC;YADG,MAAM,CAAC,IAAI,CAAC,cAAc,CAAC,IAAI,EAAE,UAAA,IAAI,IAAI,OAAA,KAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAApB,CAAoB,CAAC,CAAC;QACnE,CAAC;QA1WL;YAAC,yCAAU;;qBAAA;QA2WX,gBAAC;IAAD,CAAC,AA1WD,IA0WC;IA1WY,iBAAS,YA0WrB,CAAA"} \ No newline at end of file diff --git a/dist/amd/index.d.ts b/dist/amd/index.d.ts deleted file mode 100644 index 8bf42a7..0000000 --- a/dist/amd/index.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -import { Configure } from './configure'; -export declare function configure(aurelia: any, configCallback: any): Promise<{}>; -export { Configure }; diff --git a/dist/amd/index.js b/dist/amd/index.js deleted file mode 100644 index 8140b33..0000000 --- a/dist/amd/index.js +++ /dev/null @@ -1,19 +0,0 @@ -define(["require", "exports", './configure'], function (require, exports, configure_1) { - "use strict"; - exports.Configure = configure_1.Configure; - function configure(aurelia, configCallback) { - var instance = aurelia.container.get(configure_1.Configure); - if (configCallback !== undefined && typeof (configCallback) === 'function') { - configCallback(instance); - } - return new Promise(function (resolve, reject) { - instance.loadConfig() - .then(function () { return resolve(); }) - .catch(function () { - reject(new Error('Configuration file could not be loaded')); - }); - }); - } - exports.configure = configure; -}); -//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/dist/amd/index.js.map b/dist/amd/index.js.map deleted file mode 100644 index f7f4050..0000000 --- a/dist/amd/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;IAmBQ,iBAAS;IAjBjB,mBAA0B,OAAO,EAAE,cAAc;QAC7C,IAAI,QAAQ,GAAG,OAAO,CAAC,SAAS,CAAC,GAAG,CAAC,qBAAS,CAAC,CAAC;QAGhD,EAAE,CAAC,CAAC,cAAc,KAAK,SAAS,IAAI,OAAM,CAAC,cAAc,CAAC,KAAK,UAAU,CAAC,CAAC,CAAC;YACxE,cAAc,CAAC,QAAQ,CAAC,CAAC;QAC7B,CAAC;QAED,MAAM,CAAC,IAAI,OAAO,CAAC,UAAC,OAAO,EAAE,MAAM;YAC/B,QAAQ,CAAC,UAAU,EAAE;iBAChB,IAAI,CAAC,cAAM,OAAA,OAAO,EAAE,EAAT,CAAS,CAAC;iBACrB,KAAK,CAAC;gBACH,MAAM,CAAC,IAAI,KAAK,CAAC,wCAAwC,CAAC,CAAC,CAAC;YAChE,CAAC,CAAC,CAAC;QACX,CAAC,CAAC,CAAC;IACP,CAAC;IAfe,iBAAS,YAexB,CAAA;IAEkB"} \ No newline at end of file diff --git a/dist/index.d.ts b/dist/index.d.ts index 8bf42a7..efb1bc8 100644 --- a/dist/index.d.ts +++ b/dist/index.d.ts @@ -1,3 +1,41 @@ -import { Configure } from './configure'; -export declare function configure(aurelia: any, configCallback: any): Promise<{}>; -export { Configure }; +declare module "configure" { + import { Loader } from 'aurelia-loader'; + export interface ConfigInterface { + } + export class Configure { + loader: Loader; + environment: string; + environments: any; + directory: string; + config_file: string; + cascade_mode: boolean; + private _config_object; + private _config_merge_object; + constructor(loader: Loader); + setDirectory(path: any): void; + setConfig(name: any): void; + setEnvironment(environment: any): void; + setEnvironments(environments?: boolean): void; + setCascadeMode(bool?: boolean): void; + readonly obj: ConfigInterface; + readonly config: string; + is(environment: any): boolean; + check(): void; + environmentEnabled(): boolean; + environmentExists(): boolean; + get(key: any, defaultValue?: any): any; + set(key: any, val: any): void; + merge(obj: any): void; + lazyMerge(obj: any): void; + setAll(obj: any): void; + getAll(): ConfigInterface; + loadConfig(): Promise; + loadConfigFile(path: any, action: any): Promise; + mergeConfigFile(path: any): Promise; + } +} +declare module "index" { + import { Configure } from "configure"; + export function configure(aurelia: any, configCallback: any): Promise<{}>; + export { Configure }; +}