sfdx-jayree 4.4.38 → 4.5.0

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.
Files changed (48) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/README.md +63 -48
  3. package/lib/commands/jayree/flowtestcoverage.js +2 -1
  4. package/lib/commands/jayree/flowtestcoverage.js.map +1 -1
  5. package/lib/commands/jayree/org/configure/country.d.ts +1 -2
  6. package/lib/commands/jayree/org/configure/country.js +19 -27
  7. package/lib/commands/jayree/org/configure/country.js.map +1 -1
  8. package/lib/commands/jayree/org/configure/index.js +16 -8
  9. package/lib/commands/jayree/org/configure/index.js.map +1 -1
  10. package/lib/commands/jayree/org/configure/state.js +23 -30
  11. package/lib/commands/jayree/org/configure/state.js.map +1 -1
  12. package/lib/commands/jayree/org/settings.js +2 -1
  13. package/lib/commands/jayree/org/settings.js.map +1 -1
  14. package/lib/commands/jayree/org/streaming.js +2 -1
  15. package/lib/commands/jayree/org/streaming.js.map +1 -1
  16. package/lib/commands/jayree/source/fix.js +2 -1
  17. package/lib/commands/jayree/source/fix.js.map +1 -1
  18. package/lib/commands/jayree/version.js +2 -1
  19. package/lib/commands/jayree/version.js.map +1 -1
  20. package/lib/hooks/changelog.d.ts +1 -1
  21. package/lib/hooks/changelog.js +8 -77
  22. package/lib/hooks/changelog.js.map +1 -1
  23. package/lib/hooks/postretrieve.js +3 -3
  24. package/lib/hooks/postretrieve.js.map +1 -1
  25. package/lib/hooks/prerun.js +3 -3
  26. package/lib/hooks/prerun.js.map +1 -1
  27. package/lib/utils/puppeteer/configuretasks.d.ts +1 -0
  28. package/lib/utils/puppeteer/configuretasks.js +18 -17
  29. package/lib/utils/puppeteer/configuretasks.js.map +1 -1
  30. package/lib/utils/puppeteer/statetasks.d.ts +26 -6
  31. package/lib/utils/puppeteer/statetasks.js +33 -61
  32. package/lib/utils/puppeteer/statetasks.js.map +1 -1
  33. package/lib/utils/renderer.d.ts +32 -163
  34. package/lib/utils/renderer.js +288 -302
  35. package/lib/utils/renderer.js.map +1 -1
  36. package/lib/utils/souceUtils.js +4 -4
  37. package/lib/utils/souceUtils.js.map +1 -1
  38. package/oclif.manifest.json +1 -220
  39. package/package.json +13 -27
  40. package/lib/commands/jayree/source/tracking/list.d.ts +0 -13
  41. package/lib/commands/jayree/source/tracking/list.js +0 -150
  42. package/lib/commands/jayree/source/tracking/list.js.map +0 -1
  43. package/lib/commands/jayree/source/tracking/store/get.d.ts +0 -10
  44. package/lib/commands/jayree/source/tracking/store/get.js +0 -58
  45. package/lib/commands/jayree/source/tracking/store/get.js.map +0 -1
  46. package/lib/commands/jayree/source/tracking/store/set.d.ts +0 -13
  47. package/lib/commands/jayree/source/tracking/store/set.js +0 -74
  48. package/lib/commands/jayree/source/tracking/store/set.js.map +0 -1
@@ -1,176 +1,45 @@
1
- import { ListrRenderer, ListrTaskObject } from 'listr2';
2
- /** Default updating renderer for Listr2 */
1
+ import type { ListrRenderer, ListrEventManager, ListrDefaultRendererOptions, ListrDefaultRendererTask, ListrDefaultRendererTaskOptions } from 'listr2';
2
+ interface MyListrDefaultRendererOptions extends ListrDefaultRendererOptions {
3
+ maxSubTasks?: number;
4
+ hideAfterSeconds?: number;
5
+ }
3
6
  export declare class MyDefaultRenderer implements ListrRenderer {
4
- tasks: Array<ListrTaskObject<any, typeof MyDefaultRenderer>>;
5
- options: typeof MyDefaultRenderer['rendererOptions'];
6
- renderHook$?: ListrTaskObject<any, any>['renderHook$'];
7
- /** designates whether this renderer can output to a non-tty console */
7
+ private readonly tasks;
8
+ private readonly options;
9
+ private readonly events;
8
10
  static nonTTY: boolean;
9
- /** renderer options for the defauult renderer */
10
- static rendererOptions: {
11
- /**
12
- * indentation per level of subtask
13
- *
14
- * @default 2
15
- */
16
- indentation?: number;
17
- /**
18
- * clear all the output generated by the renderer when the task finishes its execution
19
- *
20
- * @default false
21
- * @global global option that can not be temperated with subtasks
22
- */
23
- clearOutput?: boolean;
24
- /**
25
- * show the subtasks of the current task
26
- *
27
- * @default true
28
- */
29
- showSubtasks?: boolean;
30
- /**
31
- * collapse subtasks after current task completes its execution
32
- *
33
- * @default true
34
- */
35
- collapse?: boolean;
36
- /**
37
- * show skip messages or show the original title of the task, this will also disable collapseSkips mode
38
- *
39
- * You can disable showing the skip messages, even though you passed in a message by settings this option,
40
- * if you want to keep the original task title intact.
41
- *
42
- * @default true
43
- */
44
- showSkipMessage?: boolean;
45
- /**
46
- * collapse skip messages into a single message and overwrite the task title
47
- *
48
- * @default true
49
- */
50
- collapseSkips?: boolean;
51
- /**
52
- * suffix skip messages with [SKIPPED] when in collapseSkips mode
53
- *
54
- * @default true
55
- */
56
- suffixSkips?: boolean;
57
- /**
58
- * shows the thrown error message or show the original title of the task, this will also disable collapseErrors mode
59
- * You can disable showing the error messages, even though you passed in a message by settings this option,
60
- * if you want to keep the original task title intact.
61
- *
62
- * @default true
63
- */
64
- showErrorMessage?: boolean;
65
- /**
66
- * collapse error messages into a single message and overwrite the task title
67
- *
68
- * @default true
69
- */
70
- collapseErrors?: boolean;
71
- /**
72
- * suffix retry messages with [RETRY-${COUNT}] when retry is enabled for a task
73
- *
74
- * @default true
75
- */
76
- suffixRetries?: boolean;
77
- /**
78
- * only update through triggers from renderhook
79
- *
80
- * useful for tests and stuff. this will disable showing spinner and only update the screen if something else has
81
- * happened in the task worthy to show
82
- *
83
- * @default false
84
- * @global global option that can not be temperated with subtasks
85
- */
86
- lazy?: boolean;
87
- /**
88
- * show duration for all tasks
89
- *
90
- * @default false
91
- * @global global option that can not be temperated with subtasks
92
- */
93
- showTimer?: boolean;
94
- /**
95
- * removes empty lines from the data output
96
- *
97
- * @default true
98
- */
99
- removeEmptyLines?: boolean;
100
- /**
101
- * formats data output depending on your requirements.
102
- *
103
- * @default 'truncate'
104
- * @global global option that can not be temperated with subtasks
105
- */
106
- formatOutput?: 'truncate' | 'wrap';
107
- /**
108
- * max subtasks to print
109
- *
110
- * @default 10
111
- */
112
- maxSubTasks?: number;
113
- /**
114
- * hide subtasks after x seconds
115
- *
116
- * @default 10
117
- */
118
- hideAfterSeconds?: number;
119
- };
120
- /** per task options for the default renderer */
121
- static rendererTaskOptions: {
122
- /**
123
- * write task output to the bottom bar instead of the gap under the task title itself.
124
- * useful for a stream of data.
125
- *
126
- * @default false
127
- *
128
- * `true` only keep 1 line of the latest data outputted by the task.
129
- * `false` only keep 1 line of the latest data outputted by the task.
130
- * `number` will keep designated data of the latest data outputted by the task.
131
- */
132
- bottomBar?: boolean | number;
133
- /**
134
- * keep output after task finishes
135
- *
136
- * @default false
137
- *
138
- * works both for the bottom bar and the default behavior
139
- */
140
- persistentOutput?: boolean;
141
- /**
142
- * show the task time if it was successful
143
- */
144
- showTimer?: boolean;
145
- };
146
- private id?;
147
- private bottomBar;
148
- private promptBar;
11
+ static rendererOptions: MyListrDefaultRendererOptions;
12
+ static rendererTaskOptions: ListrDefaultRendererTaskOptions;
13
+ private bottom;
14
+ private prompt;
15
+ private activePrompt;
149
16
  private readonly spinner;
150
- private spinnerPosition;
17
+ private readonly logger;
18
+ private updater;
19
+ private truncate;
20
+ private wrap;
151
21
  private taskTime;
152
22
  private currentTasks;
153
23
  private hiddenTasks;
154
- constructor(tasks: Array<ListrTaskObject<any, typeof MyDefaultRenderer>>, options: typeof MyDefaultRenderer['rendererOptions'], renderHook$?: ListrTaskObject<any, any>['renderHook$']);
155
- private static getTaskOptions;
156
- private static isBottomBar;
157
- private static hasPersistentOutput;
158
- private static hasTimer;
159
- private static getTaskTime;
160
- private static indentMultilineOutput;
161
- private static addSuffixToMessage;
162
- getSelfOrParentOption<T extends keyof typeof MyDefaultRenderer['rendererOptions']>(task: ListrTaskObject<any, typeof MyDefaultRenderer>, key: T): typeof MyDefaultRenderer['rendererOptions'][T];
163
- createRender(options?: {
24
+ constructor(tasks: ListrDefaultRendererTask[], options: MyListrDefaultRendererOptions, events: ListrEventManager);
25
+ getTaskOptions(task: ListrDefaultRendererTask): ListrDefaultRendererTaskOptions;
26
+ isBottomBar(task: ListrDefaultRendererTask): boolean;
27
+ hasPersistentOutput(task: ListrDefaultRendererTask): boolean;
28
+ getSelfOrParentOption<K extends keyof ListrDefaultRendererOptions>(task: ListrDefaultRendererTask, key: K): ListrDefaultRendererOptions[K];
29
+ render(): Promise<void>;
30
+ update(): void;
31
+ end(): void;
32
+ create(options?: {
164
33
  tasks?: boolean;
165
34
  bottomBar?: boolean;
166
35
  prompt?: boolean;
167
36
  }): string;
168
- render(): void;
169
- end(): void;
170
- private multiLineRenderer;
37
+ protected style(task: ListrDefaultRendererTask, output?: boolean): string;
38
+ protected format(message: string, icon: string, level: number): string[];
39
+ private renderer;
171
40
  private renderBottomBar;
172
41
  private renderPrompt;
173
- private dumpData;
174
- private formatString;
175
- private getSymbol;
42
+ private dump;
43
+ private indent;
176
44
  }
45
+ export {};