Comparing version 1.0.14 to 1.0.15
@@ -76,3 +76,3 @@ "use strict"; | ||
desc: "Returns the set of distinct values from the input dataset. Removes duplicate values from the dataset.", | ||
syntax: "distinct <input-file> [<output-file>]", | ||
syntax: "distinct [<input-file>] [<output-file>]", | ||
inputs: help_1.standardCmdInputs, | ||
@@ -79,0 +79,0 @@ outputs: help_1.standardCmdOutputs, |
@@ -47,2 +47,3 @@ "use strict"; | ||
var help_1 = require("./lib/help"); | ||
var verify_1 = require("../lib/verify"); | ||
function main(argv) { | ||
@@ -56,2 +57,3 @@ return __awaiter(this, void 0, void 0, function () { | ||
data = _a.sent(); | ||
(0, verify_1.verifyInputArray)(data, "format-table"); | ||
header = data.length > 0 ? Object.keys(data[0]) : []; | ||
@@ -70,3 +72,3 @@ boldHeader = header.map(function (column) { return chalk_1.default.bold(column); }); | ||
desc: "Formats data to table rendered in ascii.", | ||
syntax: "format-table <input-file>", | ||
syntax: "format-table [<input-file>]", | ||
inputs: help_1.standardCmdInputs, | ||
@@ -73,0 +75,0 @@ outputs: [ |
@@ -61,3 +61,3 @@ "use strict"; | ||
desc: "Formats data to tree rendered in ascii.", | ||
syntax: "format-tree <input-file>", | ||
syntax: "format-tree [<input-file>]", | ||
inputs: help_1.standardCmdInputs, | ||
@@ -64,0 +64,0 @@ outputs: [ |
@@ -62,3 +62,3 @@ "use strict"; | ||
desc: "Converts data from the CSV (comma separated values) data format to the JSON data format.", | ||
syntax: "from-csv <csv-input-file> [<output-file>]", | ||
syntax: "from-csv [<csv-input-file>] [<output-file>]", | ||
inputs: [ | ||
@@ -65,0 +65,0 @@ "CSV file", |
@@ -62,3 +62,3 @@ "use strict"; | ||
desc: "Converts data from the YAML data format to the JSON data format.", | ||
syntax: "from-yaml <yaml-input-file> [<output-file>]", | ||
syntax: "from-yaml [<yaml-input-file>] [<output-file>]", | ||
inputs: [ | ||
@@ -65,0 +65,0 @@ "YAML file", |
@@ -41,2 +41,3 @@ "use strict"; | ||
var io_1 = require("../lib/io"); | ||
var verify_1 = require("../lib/verify"); | ||
function main(argv) { | ||
@@ -50,2 +51,3 @@ return __awaiter(this, void 0, void 0, function () { | ||
data = _a.sent(); | ||
(0, verify_1.verifyInputArray)(data, "length"); | ||
return [4 /*yield*/, (0, io_1.outputData)(argv, data.length)]; | ||
@@ -63,3 +65,3 @@ case 2: | ||
desc: "Gets the number of records in a dataset. Works just like `array.length` in JavaScript.", | ||
syntax: "length <input-file>", | ||
syntax: "length [<input-file>]", | ||
inputs: [ | ||
@@ -66,0 +68,0 @@ "JSON file", |
@@ -41,2 +41,3 @@ "use strict"; | ||
var io_1 = require("../lib/io"); | ||
var verify_1 = require("../lib/verify"); | ||
var help_1 = require("./lib/help"); | ||
@@ -51,2 +52,3 @@ function main(argv) { | ||
data = _a.sent(); | ||
(0, verify_1.verifyInputArray)(data, "to-csv"); | ||
return [4 /*yield*/, (0, io_1.outputData)(argv, data, "csv")]; | ||
@@ -53,0 +55,0 @@ case 2: |
{ | ||
"name": "datakit", | ||
"version": "1.0.14", | ||
"version": "1.0.15", | ||
"description": "Simple JavaScript toolkit for data transform across JSON, CSV and YAML.", | ||
@@ -62,3 +62,3 @@ "main": "build/index.js", | ||
"skip": "./cli/skip", | ||
"sort": "./cli/sort", | ||
"orderBy": "./cli/sort", | ||
"take": "./cli/take", | ||
@@ -65,0 +65,0 @@ "to-csv": "./cli/to-csv", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
244016
4239