@littlecarlito/blorktools 0.52.0 → 0.52.2

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/bin/cli.js CHANGED
@@ -7,7 +7,7 @@ const __dirname = path.dirname(fileURLToPath(import.meta.url));
7
7
  const packageRoot = path.resolve(__dirname, '..');
8
8
  const SUBCOMMANDS = {
9
9
  debugger: {
10
- path: '/asset_debugger/index.html',
10
+ root: 'src/asset_debugger',
11
11
  description: '3D asset debugger with drag-and-drop interface'
12
12
  }
13
13
  };
@@ -72,16 +72,17 @@ function parseArgs(args) {
72
72
 
73
73
  async function main() {
74
74
  const args = parseArgs(process.argv.slice(2));
75
- const openPath = args.command ? SUBCOMMANDS[args.command].path : '/index.html';
75
+ const subcommand = args.command ? SUBCOMMANDS[args.command] : null;
76
+ const rootDir = subcommand ? path.join(packageRoot, subcommand.root) : path.join(packageRoot, 'src');
76
77
  const viteConfig = await import(path.join(packageRoot, 'vite.config.js'));
77
78
  const config = viteConfig.default;
78
79
  config.server = {
79
80
  ...config.server,
80
81
  port: args.port,
81
82
  host: args.host,
82
- open: args.open ? openPath : false
83
+ open: args.open ? '/index.html' : false
83
84
  };
84
- config.root = path.join(packageRoot, 'src');
85
+ config.root = rootDir;
85
86
  const server = await createServer(config);
86
87
  await server.listen();
87
88
  server.printUrls();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@littlecarlito/blorktools",
3
- "version": "0.52.0",
3
+ "version": "0.52.2",
4
4
  "description": "Development tools for 3D assets and debugging",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",
@@ -45,5 +45,5 @@
45
45
  "access": "public"
46
46
  },
47
47
  "license": "SEE LICENSE IN LICENSE",
48
- "gitHead": "023438080a377994f54a129ec9bbefb4bf1e10dd"
48
+ "gitHead": "d317bcab9cd34ab37fb893963345b54582047c5d"
49
49
  }
package/vite.config.js CHANGED
@@ -43,6 +43,7 @@ export default defineConfig({
43
43
  open: '/index.html',
44
44
  port: 3001,
45
45
  strictPort: true,
46
+ allowedHosts: true,
46
47
  fs: {
47
48
  allow: [__dirname]
48
49
  },