trello-cli-unofficial 0.11.2 → 0.11.4

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/CHANGELOG.md CHANGED
@@ -1,3 +1,18 @@
1
+ ## [0.11.4](https://github.com/JaegerCaiser/trello-cli-unofficial/compare/v0.11.3...v0.11.4) (2025-11-14)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * Initialize Commander.js in constructor to fix Windows compatibility ([7762da8](https://github.com/JaegerCaiser/trello-cli-unofficial/commit/7762da85b532e90e68be3717609639f838c88b45))
7
+ * revert to synchronous Commander import for Windows compatibility ([badcea4](https://github.com/JaegerCaiser/trello-cli-unofficial/commit/badcea41b971e8e5dbb1ba8993f9661cb01d7358))
8
+
9
+ ## [0.11.3](https://github.com/JaegerCaiser/trello-cli-unofficial/compare/v0.11.2...v0.11.3) (2025-11-14)
10
+
11
+
12
+ ### Bug Fixes
13
+
14
+ * switch to dynamic Commander import for better Windows compatibility ([e1ea7c5](https://github.com/JaegerCaiser/trello-cli-unofficial/commit/e1ea7c588a10a635365a14099e7d6902a8f0eacb))
15
+
1
16
  ## [0.11.2](https://github.com/JaegerCaiser/trello-cli-unofficial/compare/v0.11.1...v0.11.2) (2025-11-14)
2
17
 
3
18
 
package/dist/main.js CHANGED
@@ -31137,23 +31137,13 @@ class CommandController {
31137
31137
  authController;
31138
31138
  boardController;
31139
31139
  cardController;
31140
- program = null;
31140
+ program;
31141
31141
  outputFormatter;
31142
31142
  constructor() {
31143
31143
  const configRepository = new FileConfigRepository;
31144
31144
  this.authController = new AuthController(configRepository);
31145
31145
  this.outputFormatter = new OutputFormatter;
31146
- }
31147
- async initializeProgram() {
31148
- if (this.program) {
31149
- return;
31150
- }
31151
- try {
31152
- this.program = new Command;
31153
- } catch (error) {
31154
- console.error(t2("menu.errors.commanderInitError"), error);
31155
- throw new Error(t2("menu.errors.commanderInitFailed"));
31156
- }
31146
+ this.program = new Command;
31157
31147
  }
31158
31148
  async initializeTrelloControllers() {
31159
31149
  await this.authController.ensureAuthenticated();
@@ -31353,14 +31343,13 @@ class CommandController {
31353
31343
  });
31354
31344
  }
31355
31345
  async run() {
31356
- await this.initializeProgram();
31357
31346
  await this.setupCommands();
31358
31347
  if (process.argv.length === 2) {
31359
31348
  const configRepository = new FileConfigRepository;
31360
31349
  const cli = new (await Promise.resolve().then(() => (init_TrelloCliController(), exports_TrelloCliController))).TrelloCliController(configRepository, this.outputFormatter);
31361
31350
  await cli.run();
31362
31351
  } else {
31363
- this.program.parse();
31352
+ await this.program.parseAsync();
31364
31353
  }
31365
31354
  }
31366
31355
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "trello-cli-unofficial",
3
3
  "type": "module",
4
- "version": "0.11.2",
4
+ "version": "0.11.4",
5
5
  "private": false,
6
6
  "description": "Unofficial Trello CLI using Power-Up authentication, built with Bun for maximum performance",
7
7
  "author": "Matheus Caiser <matheus.kaiser@gmail.com> (https://www.mrdeveloper.com.br/)",
@@ -1,6 +1,5 @@
1
1
  import type { OutputFormat } from '@/shared';
2
2
  import { readFileSync } from 'node:fs';
3
-
4
3
  import { join } from 'node:path';
5
4
 
6
5
  import { AuthenticationService } from '@domain/services';
@@ -8,38 +7,26 @@ import {
8
7
  FileConfigRepository,
9
8
  TrelloApiRepository,
10
9
  } from '@infrastructure/repositories';
11
- import { Command } from 'commander';
12
10
 
11
+ import { Command } from 'commander';
13
12
  import { t } from '@/i18n';
14
13
  import { OutputFormatter } from '@/shared';
14
+
15
15
  import { AuthController, BoardController, CardController } from './index';
16
16
 
17
17
  export class CommandController {
18
18
  private authController: AuthController;
19
19
  private boardController!: BoardController;
20
20
  private cardController!: CardController;
21
- private program: Command | null = null;
21
+ private program: Command;
22
22
  private outputFormatter: OutputFormatter;
23
23
 
24
24
  constructor() {
25
25
  const configRepository = new FileConfigRepository();
26
26
  this.authController = new AuthController(configRepository);
27
27
  this.outputFormatter = new OutputFormatter();
28
- // Commander will be initialized lazily in run()
29
- }
30
-
31
- private async initializeProgram(): Promise<void> {
32
- if (this.program) {
33
- return;
34
- }
35
-
36
- try {
37
- // Use static import - Commander is already imported at the top
38
- this.program = new Command();
39
- } catch (error) {
40
- console.error(t('menu.errors.commanderInitError'), error);
41
- throw new Error(t('menu.errors.commanderInitFailed'));
42
- }
28
+ // Initialize Commander immediately in constructor
29
+ this.program = new Command();
43
30
  }
44
31
 
45
32
  private async initializeTrelloControllers(): Promise<void> {
@@ -450,7 +437,6 @@ export class CommandController {
450
437
  }
451
438
 
452
439
  async run(): Promise<void> {
453
- await this.initializeProgram();
454
440
  await this.setupCommands();
455
441
 
456
442
  // Fallback to interactive mode if no command specified
@@ -461,7 +447,7 @@ export class CommandController {
461
447
  ).TrelloCliController(configRepository, this.outputFormatter);
462
448
  await cli.run();
463
449
  } else {
464
- this.program!.parse();
450
+ await this.program.parseAsync();
465
451
  }
466
452
  }
467
453
  }