jiradc-cli 1.0.7 → 1.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +9 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -68,8 +68,12 @@ function stripResponse(obj) {
|
|
|
68
68
|
}
|
|
69
69
|
|
|
70
70
|
// src/utils/output.ts
|
|
71
|
+
var prettyPrint = false;
|
|
72
|
+
function setPretty(value) {
|
|
73
|
+
prettyPrint = value;
|
|
74
|
+
}
|
|
71
75
|
function output(data) {
|
|
72
|
-
process.stdout.write(`${JSON.stringify(stripResponse(data), null, 2)}
|
|
76
|
+
process.stdout.write(`${JSON.stringify(stripResponse(data), null, prettyPrint ? 2 : void 0)}
|
|
73
77
|
`);
|
|
74
78
|
}
|
|
75
79
|
function handleError(err) {
|
|
@@ -1106,6 +1110,10 @@ ${styleText("bold", "Examples:")}
|
|
|
1106
1110
|
${DIM}$${RESET} jiradc sprint list --board 42 --state active
|
|
1107
1111
|
`
|
|
1108
1112
|
);
|
|
1113
|
+
program.option("--pretty", "Pretty-print JSON output");
|
|
1114
|
+
program.hook("preAction", (thisCommand) => {
|
|
1115
|
+
if (thisCommand.optsWithGlobals().pretty) setPretty(true);
|
|
1116
|
+
});
|
|
1109
1117
|
registerIssueCommands(program);
|
|
1110
1118
|
registerProjectCommands(program);
|
|
1111
1119
|
registerBoardCommands(program);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jiradc-cli",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.8",
|
|
4
4
|
"publish": true,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
"tsx": "^4.19.2",
|
|
23
23
|
"typescript": "^5.7.2",
|
|
24
24
|
"vitest": "^4.0.16",
|
|
25
|
-
"config-
|
|
26
|
-
"config-
|
|
25
|
+
"config-eslint": "0.0.0",
|
|
26
|
+
"config-typescript": "0.0.0"
|
|
27
27
|
},
|
|
28
28
|
"engines": {
|
|
29
29
|
"node": ">=22.0.0"
|