diff --git a/bin/run.bat b/bin/run.bat new file mode 100644 index 0000000..c46f9e3 --- /dev/null +++ b/bin/run.bat @@ -0,0 +1,11 @@ +@echo off + +echo Starting ComfyBox. +echo Be sure you've started ComfyUI already using this command: +echo[ +echo python main.py --enable-cors-header +echo[ +echo Serving at http://localhost:8000 +echo[ + +python -m http.server 8000 diff --git a/bin/run.sh b/bin/run.sh new file mode 100644 index 0000000..c121467 --- /dev/null +++ b/bin/run.sh @@ -0,0 +1,11 @@ +#!/usr/bin/env sh + +echo "Starting ComfyBox." +echo "Be sure you've started ComfyUI already using this command:" +echo "" +echo " python main.py --enable-cors-header" +echo "" +echo "Serving at http://localhost:8000" +echo "" + +python -m http.server 8000 diff --git a/dist/.keep b/dist/.keep deleted file mode 100644 index e69de29..0000000 diff --git a/litegraph b/litegraph index 4500dec..6cbae97 160000 --- a/litegraph +++ b/litegraph @@ -1 +1 @@ -Subproject commit 4500dec3b95f3d10f70cbd415780eb4884d2800e +Subproject commit 6cbae97b3c385dba16b9100352428af4d6219dae diff --git a/package.json b/package.json index 9d255c3..21713bd 100644 --- a/package.json +++ b/package.json @@ -27,6 +27,7 @@ "svelte-dnd-action": "^0.9.22", "typescript": "^5.0.3", "vite": "^4.3.1", + "vite-plugin-static-copy": "^0.14.0", "vite-tsconfig-paths": "^4.0.8", "vitest": "^0.25.8" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 64cd3ce..9cdbb2a 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -125,6 +125,9 @@ importers: vite: specifier: ^4.3.1 version: 4.3.1(sass@1.61.0) + vite-plugin-static-copy: + specifier: ^0.14.0 + version: 0.14.0(vite@4.3.1) vite-tsconfig-paths: specifier: ^4.0.8 version: 4.0.8(typescript@5.0.3)(vite@4.3.1) @@ -7084,6 +7087,19 @@ packages: vite: 4.3.1(sass@1.61.0) dev: false + /vite-plugin-static-copy@0.14.0(vite@4.3.1): + resolution: {integrity: sha512-RMFmb4czomcrsbQBiUZs9HcDGN3kxGvF+OrtkfTVocp12CuoUCuJQhcY26RK35A6KS4WasGzEwcYZqHMjkAvVw==} + engines: {node: ^14.18.0 || >=16.0.0} + peerDependencies: + vite: ^3.0.0 || ^4.0.0 + dependencies: + chokidar: 3.5.3 + fast-glob: 3.2.12 + fs-extra: 11.1.1 + picocolors: 1.0.0 + vite: 4.3.1(sass@1.61.0) + dev: true + /vite-tsconfig-paths@4.0.8(typescript@5.0.3)(vite@4.3.1): resolution: {integrity: sha512-p04zH+Ey+NT78571x0pdX7nVRIJSlmKVvYryFglSWOK3Hc72eDL0+JJfbyQiugaIBApJkaEqbBQvqpsFZOSVGg==} peerDependencies: diff --git a/run.bat b/run.bat deleted file mode 100644 index 53da77d..0000000 --- a/run.bat +++ /dev/null @@ -1,4 +0,0 @@ -@echo off - -pushd dist -python -m http.server 8000 diff --git a/run.sh b/run.sh deleted file mode 100644 index c673001..0000000 --- a/run.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/usr/bin/env sh - -pushd dist/ -python -m http.server 8000 diff --git a/vite.config.ts b/vite.config.ts index 2c68c66..28221f3 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -3,12 +3,25 @@ import { defineConfig } from 'vitest/config'; import { resolve } from 'path'; import tsconfigPaths from 'vite-tsconfig-paths'; import FullReload from 'vite-plugin-full-reload'; +import { viteStaticCopy } from 'vite-plugin-static-copy' export default defineConfig({ clearScreen: false, plugins: [ FullReload(["src/**/*.{js,ts,svelte}"]), - svelte(), + svelte(), , + viteStaticCopy({ + targets: [ + { + src: 'bin/run.sh', + dest: './' + }, + { + src: 'bin/run.bat', + dest: './' + } + ] + }) ], resolve: { alias: {