feat: add helpers and improve workspace auth flows
This commit is contained in:
@@ -43,6 +43,8 @@ Usage:
|
||||
wrnexus build [app-dir] Build a production server bundle + assets
|
||||
wrnexus create <app-name> Scaffold a new app
|
||||
wrnexus workspace <name> Scaffold a monorepo (apps/* + shared packages/*)
|
||||
wrnexus workspace add <name> [--domain=name.localhost]
|
||||
Add an app to the current workspace
|
||||
wrnexus gateway [--port=3000] Serve every workspace app behind one port, routed by domain
|
||||
wrnexus generate <type> <name> Scaffold a page | component | api | schema
|
||||
wrnexus generate routes | docker | mobile
|
||||
@@ -92,8 +94,12 @@ async function main(): Promise<void> {
|
||||
createApp(rest[0] ?? "");
|
||||
break;
|
||||
case "workspace": {
|
||||
const { createWorkspace } = await import("./workspace.ts");
|
||||
createWorkspace(rest.find((a) => !a.startsWith("--")) ?? "");
|
||||
const { addWorkspaceApp, createWorkspace } = await import("./workspace.ts");
|
||||
if (rest[0] === "add") {
|
||||
await addWorkspaceApp(".", rest[1] ?? "", rest.slice(2));
|
||||
} else {
|
||||
createWorkspace(rest.find((a) => !a.startsWith("--")) ?? "");
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "gateway": {
|
||||
|
||||
Reference in New Issue
Block a user