You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 9b831aa
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: cli/src/templates.rs
+10-4Lines changed: 10 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -255,7 +255,10 @@ impl ProjectTemplate {
255
255
created_paths.push(toml_path);
256
256
257
257
let app_path = dir.join("app.txs");
258
-
let app_content = format!("site \"{}\"\n", name);
258
+
let app_content = format!(
259
+
"make a website called {}\n\nheader:\n title is \"{}\"\n nav:\n link:\n label is \"Home\"\n url is \"/\"\n link:\n label is \"About\"\n url is \"/about\"\n link:\n label is \"Docs\"\n url is \"https://is-a.dev/techscript/\"\n\nfooter:\n section:\n title is \"{}\"\n link:\n label is \"Home\"\n url is \"/\"\n link:\n label is \"About\"\n url is \"/about\"\n section:\n title is \"TechScript\"\n link:\n label is \"Documentation\"\n url is \"https://is-a.dev/techscript/\"\n link:\n label is \"GitHub Repository\"\n url is \"https://github.com/Tcode-Motion/techscript\"\n\nstart website\n",
260
+
name, name, name
261
+
);
259
262
std::fs::write(&app_path, app_content)?;
260
263
created_paths.push(app_path);
261
264
@@ -264,14 +267,17 @@ impl ProjectTemplate {
264
267
265
268
let home_path = pages_dir.join("home.txs");
266
269
let home_content = format!(
267
-
"page Home \"/\":\n title \"Welcome to {}\"\n text \"Crafted with TechScript and WebForge.\"\n button \"Get Started\" -> open About\n",
270
+
"page Home \"/\":\n title \"Welcome to {}\"\n text \"A clean, modern website built with TechScript & WebForge.\"\ntext \"Edit pages/home.txs or app.txs to start customizing your application.\"\nbutton \"Explore Documentation\" -> open \"https://is-a.dev/techscript/\"\n button \"About This Site\" -> open About\n",
268
271
name
269
272
);
270
273
std::fs::write(&home_path, home_content)?;
271
274
created_paths.push(home_path);
272
275
273
276
let about_path = pages_dir.join("about.txs");
274
-
let about_content = "page About \"/about\":\n title \"About This Site\"\n text \"TechScript + WebForge delivers beginner-friendly, concise web development.\"\n button \"Back to Home\" -> open Home\n";
277
+
let about_content = format!(
278
+
"page About \"/about\":\n title \"About {}\"\n text \"This project is powered by TechScript 2.0 and WebForge.\"\n text \"TechScript provides a readable, full-stack programming experience with native compilation and zero-config servers.\"\n button \"Back to Home\" -> open Home\n",
279
+
name
280
+
);
275
281
std::fs::write(&about_path, about_content)?;
276
282
created_paths.push(about_path);
277
283
@@ -281,7 +287,7 @@ impl ProjectTemplate {
281
287
282
288
let readme_path = dir.join("README.md");
283
289
let readme_content = format!(
284
-
"# {}\n\nWebsite built with **TechScript + WebForge**.\n\n## Project Structure\n```text\n├── webforge.toml # Project configuration\n├── app.txs # Application entry\n├── pages/\n│ ├── home.txs # Home page\n│ └── about.txs # About page\n├── assets/\n│ ├── images/ # Images\n│ └── models/ # 3D models\n└── README.md\n```\n\n## Getting Started\n\nStart development server:\n```bash\nwebforge dev\n```\nVisit `http://localhost:3000` in your browser.\n\n## Production Build\n```bash\nwebforge build web --release\n```\n",
290
+
"# {}\n\nA clean, modern website built with **TechScript & WebForge**.\n\n## Project Structure\n```text\n├── webforge.toml # Project configuration\n├── app.txs # Application entry (header, navigation bar, footer)\n├── pages/\n│ ├── home.txs # Welcome / home page\n│ └── about.txs # About page\n├── assets/\n│ ├── images/ # Images\n│ └── models/ # 3D models\n└── README.md\n```\n\n## Getting Started\n\nStart live development server:\n```bash\ntsc dev\n```\nVisit `http://localhost:3000` in your browser.\n\n## Production Build\n```bash\ntsc build --target web\n```\n",
0 commit comments