syntaur 0.1.5 → 0.1.6
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/dist/index.js
CHANGED
|
@@ -7221,6 +7221,9 @@ function createDashboardServer(options) {
|
|
|
7221
7221
|
// src/commands/dashboard.ts
|
|
7222
7222
|
init_paths();
|
|
7223
7223
|
init_fs();
|
|
7224
|
+
function didUserSpecifyDashboardPort(argv = process.argv) {
|
|
7225
|
+
return argv.some((arg) => arg === "--port" || arg.startsWith("--port="));
|
|
7226
|
+
}
|
|
7224
7227
|
function resolveDashboardMode(options) {
|
|
7225
7228
|
const devMode = Boolean(options.dev);
|
|
7226
7229
|
const serverOnly = Boolean(options.serverOnly || options.apiOnly);
|
|
@@ -7244,7 +7247,7 @@ async function isPortAvailable(port) {
|
|
|
7244
7247
|
tester.once("listening", () => {
|
|
7245
7248
|
tester.close(() => resolveAvailability(true));
|
|
7246
7249
|
});
|
|
7247
|
-
tester.listen(port
|
|
7250
|
+
tester.listen(port);
|
|
7248
7251
|
});
|
|
7249
7252
|
}
|
|
7250
7253
|
async function findAvailablePort(startPort, maxAttempts = 20) {
|
|
@@ -9448,9 +9451,9 @@ program.command("create-assignment").description("Create a new assignment within
|
|
|
9448
9451
|
process.exit(1);
|
|
9449
9452
|
}
|
|
9450
9453
|
});
|
|
9451
|
-
program.command("dashboard").description("Start the local Syntaur dashboard web UI").option("--port <number>", "Port to run the dashboard on", "4800").option("--dev", "Run the dashboard with the Vite dev server", false).option("--server-only", "Run only the API server without any UI", false).option("--api-only", "Deprecated alias for --server-only", false).option("--no-open", "Do not automatically open the browser").action(async (options
|
|
9454
|
+
program.command("dashboard").description("Start the local Syntaur dashboard web UI").option("--port <number>", "Port to run the dashboard on", "4800").option("--dev", "Run the dashboard with the Vite dev server", false).option("--server-only", "Run only the API server without any UI", false).option("--api-only", "Deprecated alias for --server-only", false).option("--no-open", "Do not automatically open the browser").action(async (options) => {
|
|
9452
9455
|
try {
|
|
9453
|
-
const autoPort =
|
|
9456
|
+
const autoPort = !didUserSpecifyDashboardPort();
|
|
9454
9457
|
await dashboardCommand({
|
|
9455
9458
|
...options,
|
|
9456
9459
|
autoPort
|