create-better-fullstack 1.1.7 → 1.1.8

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/cli.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { o as createBtsCli } from "./src-bp7xdTNG.mjs";
2
+ import { o as createBtsCli } from "./src-CiDXRNuh.mjs";
3
3
 
4
4
  //#region src/cli.ts
5
5
  createBtsCli().run();
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
1
  #!/usr/bin/env node
2
- import { a as create, c as docs, d as sponsors, i as builder, l as generateVirtualProject, n as TEMPLATE_COUNT, o as createBtsCli, r as VirtualFileSystem, s as createVirtual, t as EMBEDDED_TEMPLATES, u as router } from "./src-bp7xdTNG.mjs";
2
+ import { a as create, c as docs, d as sponsors, i as builder, l as generateVirtualProject, n as TEMPLATE_COUNT, o as createBtsCli, r as VirtualFileSystem, s as createVirtual, t as EMBEDDED_TEMPLATES, u as router } from "./src-CiDXRNuh.mjs";
3
3
 
4
4
  export { EMBEDDED_TEMPLATES, TEMPLATE_COUNT, VirtualFileSystem, builder, create, createBtsCli, createVirtual, docs, generateVirtualProject, router, sponsors };
@@ -5799,7 +5799,11 @@ async function getDockerStatus(database) {
5799
5799
  //#endregion
5800
5800
  //#region src/helpers/core/post-installation.ts
5801
5801
  async function displayPostInstallInstructions(config) {
5802
- const { api, database, relativePath, packageManager, depsInstalled, orm, addons, runtime, frontend, backend, dbSetup, webDeploy, serverDeploy } = config;
5802
+ const { api, database, relativePath, packageManager, depsInstalled, orm, addons, runtime, frontend, backend, dbSetup, webDeploy, serverDeploy, ecosystem } = config;
5803
+ if (ecosystem === "rust") {
5804
+ displayRustInstructions(config);
5805
+ return;
5806
+ }
5803
5807
  const isConvex = backend === "convex";
5804
5808
  const isBackendSelf = backend === "self";
5805
5809
  const runCmd = packageManager === "npm" ? "npm run" : packageManager === "pnpm" ? "pnpm run" : "bun run";
@@ -5967,6 +5971,48 @@ function getAlchemyDeployInstructions(runCmd, webDeploy, serverDeploy, backend)
5967
5971
  else if (webDeploy === "cloudflare" && (serverDeploy === "cloudflare" || isBackendSelf)) instructions.push(`${pc.bold("Deploy with Alchemy:")}\n${pc.cyan("•")} Dev: ${`${runCmd} dev`}\n${pc.cyan("•")} Deploy: ${`${runCmd} deploy`}\n${pc.cyan("•")} Destroy: ${`${runCmd} destroy`}`);
5968
5972
  return instructions.length ? `\n${instructions.join("\n")}` : "";
5969
5973
  }
5974
+ function displayRustInstructions(config) {
5975
+ const { relativePath, rustWebFramework, rustFrontend, rustOrm, rustApi, rustCli } = config;
5976
+ const cdCmd = `cd ${relativePath}`;
5977
+ let output = `${pc.bold("Next steps")}\n${pc.cyan("1.")} ${cdCmd}\n`;
5978
+ let stepCounter = 2;
5979
+ output += `${pc.cyan(`${stepCounter++}.`)} cargo build\n`;
5980
+ output += `${pc.cyan(`${stepCounter++}.`)} cargo run\n`;
5981
+ output += `\n${pc.bold("Your Rust project includes:")}\n`;
5982
+ if (rustWebFramework && rustWebFramework !== "none") output += `${pc.cyan("•")} Web Framework: ${{
5983
+ actix: "Actix Web",
5984
+ axum: "Axum",
5985
+ rocket: "Rocket"
5986
+ }[rustWebFramework] || rustWebFramework}\n`;
5987
+ if (rustFrontend && rustFrontend !== "none") output += `${pc.cyan("•")} Frontend: ${{
5988
+ leptos: "Leptos",
5989
+ dioxus: "Dioxus",
5990
+ yew: "Yew"
5991
+ }[rustFrontend] || rustFrontend}\n`;
5992
+ if (rustOrm && rustOrm !== "none") output += `${pc.cyan("•")} Database: ${{
5993
+ diesel: "Diesel",
5994
+ sqlx: "SQLx",
5995
+ "sea-orm": "SeaORM"
5996
+ }[rustOrm] || rustOrm}\n`;
5997
+ if (rustApi && rustApi !== "none") output += `${pc.cyan("•")} API: ${{
5998
+ "async-graphql": "async-graphql",
5999
+ juniper: "Juniper"
6000
+ }[rustApi] || rustApi}\n`;
6001
+ if (rustCli && rustCli !== "none") output += `${pc.cyan("•")} CLI: ${{
6002
+ clap: "Clap",
6003
+ ratatui: "Ratatui"
6004
+ }[rustCli] || rustCli}\n`;
6005
+ output += `\n${pc.bold("Common Cargo commands:")}\n`;
6006
+ output += `${pc.cyan("•")} Build: cargo build\n`;
6007
+ output += `${pc.cyan("•")} Run: cargo run\n`;
6008
+ output += `${pc.cyan("•")} Test: cargo test\n`;
6009
+ output += `${pc.cyan("•")} Check: cargo check\n`;
6010
+ output += `${pc.cyan("•")} Format: cargo fmt\n`;
6011
+ output += `${pc.cyan("•")} Lint: cargo clippy\n`;
6012
+ output += `\n${pc.bold("Like Better Fullstack?")} Please consider giving us a star\n on GitHub:\n`;
6013
+ output += pc.cyan("https://github.com/Marve10s/Better-Fullstack");
6014
+ consola$1.box(output);
6015
+ }
5970
6016
 
5971
6017
  //#endregion
5972
6018
  //#region src/helpers/core/create-project.ts
@@ -5987,7 +6033,7 @@ async function createProject(options, cliInput = {}) {
5987
6033
  await writeBtsConfig(options);
5988
6034
  await formatProject(projectDir);
5989
6035
  if (!isSilent()) log.success("Project template successfully scaffolded!");
5990
- if (options.install) await installDependencies({
6036
+ if (options.install && options.ecosystem !== "rust") await installDependencies({
5991
6037
  projectDir,
5992
6038
  packageManager: options.packageManager
5993
6039
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-better-fullstack",
3
- "version": "1.1.7",
3
+ "version": "1.1.8",
4
4
  "description": "A CLI-first toolkit for building Full Stack applications. Skip the configuration. Ship the code.",
5
5
  "keywords": [
6
6
  "better-auth",
@@ -72,8 +72,8 @@
72
72
  "prepublishOnly": "npm run build"
73
73
  },
74
74
  "dependencies": {
75
- "@better-fullstack/template-generator": "^1.1.7",
76
- "@better-fullstack/types": "^1.1.7",
75
+ "@better-fullstack/template-generator": "^1.1.8",
76
+ "@better-fullstack/types": "^1.1.8",
77
77
  "@clack/core": "^0.5.0",
78
78
  "@clack/prompts": "^1.0.0-alpha.8",
79
79
  "@orpc/server": "^1.13.0",