diff --git a/dist/index.js b/dist/index.js
index 8302516..24a9132 100644
--- a/dist/index.js
+++ b/dist/index.js
@@ -1,8 +1,11 @@
+"use strict";
///
-var git = require("./smartstring.git");
+var SmartstringGit = require("./smartstring.git");
+var SmartstringDocker = require("./smartstring.docker");
var smartstring = {
- git: git
+ git: SmartstringGit,
+ docker: SmartstringDocker
};
module.exports = smartstring;
-//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImluZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLDRDQUE0QztBQUM1QyxJQUFPLEdBQUcsV0FBVyxtQkFBbUIsQ0FBQyxDQUFDO0FBRTFDLElBQUksV0FBVyxHQUFHO0lBQ2QsR0FBRyxFQUFHLEdBQUc7Q0FDWixDQUFDO0FBRUYsaUJBQVMsV0FBVyxDQUFDIiwiZmlsZSI6ImluZGV4LmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8vIDxyZWZlcmVuY2UgcGF0aD1cIi4vdHlwaW5ncy9tYWluLmQudHNcIiAvPlxuaW1wb3J0IGdpdCA9IHJlcXVpcmUoXCIuL3NtYXJ0c3RyaW5nLmdpdFwiKTtcblxubGV0IHNtYXJ0c3RyaW5nID0ge1xuICAgIGdpdCA6IGdpdFxufTtcblxuZXhwb3J0ID0gc21hcnRzdHJpbmc7Il0sInNvdXJjZVJvb3QiOiIvc291cmNlLyJ9
+//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImluZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFBQSw0Q0FBNEM7QUFDNUMsSUFBTyxjQUFjLFdBQVcsbUJBQW1CLENBQUMsQ0FBQztBQUNyRCxJQUFPLGlCQUFpQixXQUFXLHNCQUFzQixDQUFDLENBQUM7QUFFM0QsSUFBSSxXQUFXLEdBQUc7SUFDZCxHQUFHLEVBQUcsY0FBYztJQUNwQixNQUFNLEVBQUUsaUJBQWlCO0NBQzVCLENBQUM7QUFFRixpQkFBUyxXQUFXLENBQUMiLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VzQ29udGVudCI6WyIvLy8gPHJlZmVyZW5jZSBwYXRoPVwiLi90eXBpbmdzL21haW4uZC50c1wiIC8+XG5pbXBvcnQgU21hcnRzdHJpbmdHaXQgPSByZXF1aXJlKFwiLi9zbWFydHN0cmluZy5naXRcIik7XG5pbXBvcnQgU21hcnRzdHJpbmdEb2NrZXIgPSByZXF1aXJlKFwiLi9zbWFydHN0cmluZy5kb2NrZXJcIik7XG5cbmxldCBzbWFydHN0cmluZyA9IHtcbiAgICBnaXQgOiBTbWFydHN0cmluZ0dpdCxcbiAgICBkb2NrZXI6IFNtYXJ0c3RyaW5nRG9ja2VyXG59O1xuXG5leHBvcnQgPSBzbWFydHN0cmluZzsiXSwic291cmNlUm9vdCI6Ii9zb3VyY2UvIn0=
diff --git a/dist/smartstring.docker.js b/dist/smartstring.docker.js
new file mode 100644
index 0000000..2c1d40c
--- /dev/null
+++ b/dist/smartstring.docker.js
@@ -0,0 +1,18 @@
+"use strict";
+/**
+ * converts an erray of env strings from docker remote api to an usable object.
+ * @param envArrayArg
+ * @returns {}
+ */
+exports.makeEnvObject = function (envArrayArg) {
+ var returnObject = {};
+ var regexString = /(.*)=(.*)/;
+ for (var envKey in envArrayArg) {
+ var regexMatches = regexString.exec(envArrayArg[envKey]);
+ returnObject[regexMatches[1]] = regexMatches[2];
+ }
+ ;
+ return returnObject;
+};
+
+//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0c3RyaW5nLmRvY2tlci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBR0E7Ozs7R0FJRztBQUNRLHFCQUFhLEdBQUcsVUFBUyxXQUFvQjtJQUNwRCxJQUFJLFlBQVksR0FBRyxFQUFFLENBQUM7SUFDdEIsSUFBSSxXQUFXLEdBQ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VzWzFdXSA9IHJlZ2V4TWF0Y2hlc1syXTtcbiAgICB9O1xuICAgIHJldHVybiByZXR1cm5PYmplY3Q7XG59OyJdLCJzb3VyY2VSb290IjoiL3NvdXJjZS8ifQ==
diff --git a/dist/smartstring.git.js b/dist/smartstring.git.js
index 2e4357d..b2ecd5c 100644
--- a/dist/smartstring.git.js
+++ b/dist/smartstring.git.js
@@ -1,3 +1,4 @@
+"use strict";
///
var plugins = require("./smartstring.plugins");
/* ---------------------------------------------- *
@@ -15,7 +16,7 @@ var gitRepo = (function () {
}
;
return gitRepo;
-})();
+}());
/* ---------------------------------------------- *
* ------------------ helpers ------------------- *
* ---------------------------------------------- */
@@ -54,4 +55,4 @@ var git = function (stringArg, tokenArg) {
};
module.exports = git;
-//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0c3RyaW5nLmdpdC50cyJdLCJuYW1lcyI6WyJnaXRSZXBvIiwiZ2l0UmVwby5jb25zdHJ1Y3RvciJdLCJtYXBwaW5ncyI6IkFBQUEsNENBQTRDO0FBQzVDLElBQU8sT0FBTyxXQUFXLHVCQUF1QixDQUFDLENBQUM7QUFFbEQ7O29EQUVvRDtBQUNwRDtJQU9JQSxpQkFBWUEsU0FBZ0JBLEVBQUNBLFFBQWdCQTtRQUN6Q0MsSUFBSUEsWUFBWUEsR0FBR0EsUUFBUUEsQ0FBQ0EsU0FBU0EsQ0FBQ0EsQ0FBQ0E7UUFDdkNBLElBQUlBLENBQUNBLElBQUlBLEdBQUdBLFlBQVlBLENBQUNBLENBQUNBLENBQUNBLENBQUNBO1FBQzVCQSxJQUFJQSxDQUFDQSxJQUFJQSxHQUFHQSxZQUFZQSxDQUFDQSxDQUFDQSxDQUFDQSxDQUFDQTtRQUM1QkEsSUFBSUEsQ0FBQ0EsSUFBSUEsR0FBR0EsWUFBWUEsQ0FBQ0EsQ0FBQ0EsQ0FBQ0EsQ0FBQ0E7UUFDNUJBLElBQUlBLEN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IFwiL1wiICsgdXNlckFyZyArIFwiL1wiICsgcmVwb0FyZyArIFwiLmdpdFwiO1xuICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgIGNhc2UgXCJzc2hcIjpcbiAgICAgICAgICAgIHJldHVyblN0cmluZyA9IFwiZ2l0QFwiICtcbiAgICAgICAgICAgICAgICBob3N0QXJnICsgXCI6XCIgKyB1c2VyQXJnICsgXCIvXCIgKyByZXBvQXJnICsgXCIuZ2l0XCI7XG4gICAgICAgICAgICBicmVhaztcbiAgICAgICAgZGVmYXVsdDpcbiAgICAgICAgICAgIHBsdWdpbnMuYmVhdXR5bG9nLmVycm9yKFwiTGluayBUeXBlIFwiICsgbGlua1R5cGVBcmcgKyBcIiBub3Qga25vd25cIik7XG4gICAgICAgICAgICBicmVhaztcbiAgICB9XG4gICAgcmV0dXJuIHJldHVyblN0cmluZztcbn07XG5cbi8qIC0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0gKlxuICogLS0tLS0tLS0tLS0tLS0tLS0tIGV4cG9ydHMgLS0tLS0tLS0tLS0tLS0tLS0tLSAqXG4gKiAtLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tICovXG5sZXQgZ2l0ID0gZnVuY3Rpb24oc3RyaW5nQXJnOnN0cmluZyx0b2tlbkFyZz86c3RyaW5nKXtcbiAgICBsZXQgbG9jYWxHaXRSZXBvID0gbmV3IGdpdFJlcG8oc3RyaW5nQXJnLHRva2VuQXJnKTtcbiAgICByZXR1cm4gbG9jYWxHaXRSZXBvO1xufTtcblxuZXhwb3J0ID0gZ2l0OyJdLCJzb3VyY2VSb290IjoiL3NvdXJjZS8ifQ==
diff --git a/dist/smartstring.plugins.js b/dist/smartstring.plugins.js
index 2a8ca9b..6207060 100644
--- a/dist/smartstring.plugins.js
+++ b/dist/smartstring.plugins.js
@@ -1,7 +1,8 @@
+"use strict";
///
var plugins = {
beautylog: require("beautylog")
};
module.exports = plugins;
-//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0c3RyaW5nLnBsdWdpbnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsNENBQTRDO0FBQzVDLElBQUksT0FBTyxHQUFHO0lBQ1YsU0FBUyxFQUFFLE9BQU8sQ0FBQyxXQUFXLENBQUM7Q0FDbEMsQ0FBQztBQUVGLGlCQUFTLE9BQU8sQ0FBQyIsImZpbGUiOiJzbWFydHN0cmluZy5wbHVnaW5zLmpzIiwic291cmNlc0NvbnRlbnQiOlsiLy8vIDxyZWZlcmVuY2UgcGF0aD1cIi4vdHlwaW5ncy9tYWluLmQudHNcIiAvPlxubGV0IHBsdWdpbnMgPSB7XG4gICAgYmVhdXR5bG9nOiByZXF1aXJlKFwiYmVhdXR5bG9nXCIpXG59O1xuXG5leHBvcnQgPSBwbHVnaW5zOyJdLCJzb3VyY2VSb290IjoiL3NvdXJjZS8ifQ==
+//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNtYXJ0c3RyaW5nLnBsdWdpbnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLDRDQUE0QztBQUM1QyxJQUFJLE9BQU8sR0FBRztJQUNWLFNBQVMsRUFBRSxPQUFPLENBQUMsV0FBVyxDQUFDO0NBQ2xDLENBQUM7QUFFRixpQkFBUyxPQUFPLENBQUMiLCJmaWxlIjoic21hcnRzdHJpbmcucGx1Z2lucy5qcyIsInNvdXJjZXNDb250ZW50IjpbIi8vLyA8cmVmZXJlbmNlIHBhdGg9XCIuL3R5cGluZ3MvbWFpbi5kLnRzXCIgLz5cbmxldCBwbHVnaW5zID0ge1xuICAgIGJlYXV0eWxvZzogcmVxdWlyZShcImJlYXV0eWxvZ1wiKVxufTtcblxuZXhwb3J0ID0gcGx1Z2luczsiXSwic291cmNlUm9vdCI6Ii9zb3VyY2UvIn0=
diff --git a/package.json b/package.json
index c4670b4..1a755cf 100644
--- a/package.json
+++ b/package.json
@@ -21,10 +21,10 @@
},
"homepage": "https://github.com/pushrocks/smartstring#readme",
"devDependencies": {
- "npmts": "^3.1.2",
- "should": "^8.2.2"
+ "npmts": "^5.0.4",
+ "should": "^8.3.1"
},
"dependencies": {
- "beautylog": "^3.0.2"
+ "beautylog": "^4.1.2"
}
}
diff --git a/test/test.js b/test/test.js
index 33680b2..373a691 100644
--- a/test/test.js
+++ b/test/test.js
@@ -25,5 +25,16 @@ describe("smartstring", function () {
.should.equal("git@github.com:pushrocks/smartstring.git");
});
});
+ describe(".docker", function () {
+ describe(".makeEnvObject", function () {
+ it("should create a Env Object", function () {
+ var envStringArray = ["VIRTUAL_HOST=sub.domain.tld", "DEFAULT_HOST=some.domain.com"];
+ var envObject = smartstring.docker.makeEnvObject(envStringArray);
+ envObject.VIRTUAL_HOST.should.equal("sub.domain.tld");
+ envObject.DEFAULT_HOST.should.equal("some.domain.com");
+ });
+ });
+ });
});
-//# sourceMappingURL=test.js.map
\ No newline at end of file
+
+//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInRlc3QudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsZ0RBQWdEO0FBQ2hELElBQUksV0FBVyxHQUFHLE9BQU8sQ0FBQyxrQkFBa0IsQ0FBQyxDQUFDO0FBQzlDLElBQUksTUFBTSxHQUFHLE9BQU8sQ0FBQyxRQUFRLENBQUMsQ0FBQztBQUUvQixRQUFRLENBQUMsYUFBYSxFQUFDO0lBQ25CLFFBQVEsQ0FBQyxRQUFRLEVBQUM7UUFDZCxJQUFJLE9BQU8sR0FBRyxXQUFXLENBQUMsR0FBRyxDQUFDLGtEQUFrRCxDQUFDLENBQUM7UUFDbEYsRUFBRSxDQUFDLHVCQUF1QixFQUFDO1lBQ3ZCLE9BQU8sQ0FBQyxJQUFJO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RvbWFpbi50bGRcIik7XG4gICAgICAgICAgICAgICAgZW52T2JqZWN0LkRFRkFVTFRfSE9TVC5zaG91bGQuZXF1YWwoXCJzb21lLmRvbWFpbi5jb21cIik7XG4gICAgICAgICAgICB9KVxuICAgICAgICB9KVxuICAgIH0pXG59KTsiXSwic291cmNlUm9vdCI6Ii9zb3VyY2UvIn0=
diff --git a/test/test.js.map b/test/test.js.map
index ed106bc..24d0938 100644
--- a/test/test.js.map
+++ b/test/test.js.map
@@ -1 +1 @@
-{"version":3,"file":"test.js","sourceRoot":"","sources":["test.ts"],"names":[],"mappings":"AAAA,gDAAgD;AAChD,IAAI,WAAW,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAC;AAC9C,IAAI,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;AAE/B,QAAQ,CAAC,aAAa,EAAC;IACnB,QAAQ,CAAC,QAAQ,EAAC;QACd,IAAI,OAAO,GAAG,WAAW,CAAC,GAAG,CAAC,kDAAkD,CAAC,CAAC;QAClF,EAAE,CAAC,uBAAuB,EAAC;YACvB,OAAO,CAAC,IAAI;iBACP,MAAM,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;QACpC,CAAC,CAAC,CAAC;QACH,EAAE,CAAC,uBAAuB,EAAC;YACvB,OAAO,CAAC,IAAI;iBACP,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC;QACnC,CAAC,CAAC,CAAC;QACH,EAAE,CAAC,uBAAuB,EAAC;YACvB,OAAO,CAAC,IAAI;iBACP,MAAM,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC;QACrC,CAAC,CAAC,CAAC;QACH,EAAE,CAAC,2BAA2B,EAAC;YAC3B,OAAO,CAAC,QAAQ;iBACX,MAAM,CAAC,KAAK,CAAC,8CAA8C,CAAC,CAAC;QACtE,CAAC,CAAC,CAAC;QACH,EAAE,CAAC,yBAAyB,EAAC;YACzB,OAAO,CAAC,MAAM;iBACT,MAAM,CAAC,KAAK,CAAC,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AA8B,CAAC,CAAC;gBACpF,IAAI,SAAS,GAAG,WAAW,CAAC,MAAM,CAAC,aAAa,CAAC,cAAc,CAAC,CAAC;gBACjE,SAAS,CAAC,YAAY,CAAC,MAAM,CAAC,KAAK,CAAC,gBAAgB,CAAC,CAAC;gBACtD,SAAS,CAAC,YAAY,CAAC,MAAM,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC;YAC3D,CAAC,CAAC,CAAA;QACN,CAAC,CAAC,CAAA;IACN,CAAC,CAAC,CAAA;AACN,CAAC,CAAC,CAAC"}
\ No newline at end of file
diff --git a/test/test.ts b/test/test.ts
index 257e4a3..7915167 100644
--- a/test/test.ts
+++ b/test/test.ts
@@ -26,4 +26,14 @@ describe("smartstring",function(){
.should.equal("git@github.com:pushrocks/smartstring.git");
});
})
+ describe(".docker",function(){
+ describe(".makeEnvObject",function(){
+ it("should create a Env Object",function(){
+ let envStringArray = ["VIRTUAL_HOST=sub.domain.tld","DEFAULT_HOST=some.domain.com"];
+ let envObject = smartstring.docker.makeEnvObject(envStringArray);
+ envObject.VIRTUAL_HOST.should.equal("sub.domain.tld");
+ envObject.DEFAULT_HOST.should.equal("some.domain.com");
+ })
+ })
+ })
});
\ No newline at end of file
diff --git a/ts/index.ts b/ts/index.ts
index beaccfe..218813a 100644
--- a/ts/index.ts
+++ b/ts/index.ts
@@ -1,8 +1,10 @@
///
-import git = require("./smartstring.git");
+import SmartstringGit = require("./smartstring.git");
+import SmartstringDocker = require("./smartstring.docker");
let smartstring = {
- git : git
+ git : SmartstringGit,
+ docker: SmartstringDocker
};
export = smartstring;
\ No newline at end of file
diff --git a/ts/smartstring.docker.ts b/ts/smartstring.docker.ts
new file mode 100644
index 0000000..bece546
--- /dev/null
+++ b/ts/smartstring.docker.ts
@@ -0,0 +1,17 @@
+///
+import plugins = require("./smartstring.plugins");
+
+/**
+ * converts an erray of env strings from docker remote api to an usable object.
+ * @param envArrayArg
+ * @returns {}
+ */
+export let makeEnvObject = function(envArrayArg:string[]){
+ let returnObject = {};
+ let regexString = /(.*)=(.*)/;
+ for(let envKey in envArrayArg){
+ let regexMatches = regexString.exec(envArrayArg[envKey]);
+ returnObject[regexMatches[1]] = regexMatches[2];
+ };
+ return returnObject;
+};
\ No newline at end of file