@openfairygui/cli 0.3.0-alpha.4 → 0.3.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openfairygui/cli",
3
- "version": "0.3.0-alpha.4",
3
+ "version": "0.3.1",
4
4
  "description": "FairyGUI Headless Authoring SDK — command-line interface.",
5
5
  "author": "OpenFairyGUI Contributors",
6
6
  "license": "MIT",
@@ -13,6 +13,9 @@
13
13
  "bugs": {
14
14
  "url": "https://github.com/OpenFairyGUI/OpenFairyGUI/issues"
15
15
  },
16
+ "engines": {
17
+ "node": ">=20"
18
+ },
16
19
  "type": "module",
17
20
  "bin": {
18
21
  "ofgui": "bin/cli.cjs",
@@ -33,13 +36,13 @@
33
36
  "restore"
34
37
  ],
35
38
  "devDependencies": {
36
- "@openfairygui/core": "0.3.0-alpha.4",
37
- "@openfairygui/functions": "0.3.0-alpha.4"
39
+ "@openfairygui/functions": "0.3.1",
40
+ "@openfairygui/core": "0.3.1"
38
41
  },
39
42
  "dependencies": {
40
43
  "commander": "^14.0.2",
41
44
  "jiti": "^2.7.0",
42
- "@openfairygui/backend": "0.3.0-alpha.4"
45
+ "@openfairygui/backend": "0.3.1"
43
46
  },
44
47
  "optionalDependencies": {
45
48
  "sharp": ">=0.33.0"
package/src/cli.ts CHANGED
@@ -27,7 +27,7 @@ function createProgram(): Command {
27
27
  ' openfairygui',
28
28
  '',
29
29
  'Input can be a .fairy file or a project root directory (auto-discovers .fairy file).',
30
- 'File extension and binary format are read from project settings.',
30
+ 'Publish settings are read from the project; --project-type applies target-specific output rules.',
31
31
  ].join('\n'),
32
32
  );
33
33
 
@@ -1,8 +1,8 @@
1
- import type { Command } from 'commander';
1
+ import path from 'node:path';
2
2
  import { NodeIO } from '@openfairygui/core/node';
3
3
  import { resolvePublishOptions } from '@openfairygui/functions';
4
4
  import { publishNode } from '@openfairygui/functions/node';
5
- import path from 'node:path';
5
+ import type { Command } from 'commander';
6
6
  import { resolveFairyPath } from '../utils/project-input.js';
7
7
  import { parseProjectType } from '../utils/project-type.js';
8
8
 
@@ -44,6 +44,7 @@ export function registerPublishCommand(program: Command): void {
44
44
  const resolved = resolvePublishOptions(doc, {
45
45
  compressed: options.compressed,
46
46
  packages: pkgFilter,
47
+ targetProjectType: projectType,
47
48
  });
48
49
 
49
50
  console.log(`Settings: ext=${resolved.fileExtension}, compressed=${resolved.compressed}`);