From bfe19a125e84419d53ca3ccf42e9bbdca2a71285 Mon Sep 17 00:00:00 2001 From: Ahmed Date: Fri, 20 Feb 2026 03:41:17 +0530 Subject: [PATCH] update readme for using the template properly --- README.md | 109 +++++++++++++++++++++++++++--------------------------- 1 file changed, 55 insertions(+), 54 deletions(-) diff --git a/README.md b/README.md index bb8d5de..bb9d1de 100644 --- a/README.md +++ b/README.md @@ -1,64 +1,65 @@ -# 🚀 Your Personal Web Dev Lab +# 🚀 The CI/CD Magic Template -Welcome to your automated web development sandbox! This repository is connected directly to a robotic server. Whenever you push your code here, the server will automatically build your website and put it on the internet. +Welcome to your deployment engine! This repository contains the "magic" `.gitea` folder that tells our server how to automatically build your website and put it on the internet. + +Because modern tools (like Vite, Next.js, or Astro) create their own brand-new folders when you scaffold them, you **will not** write your code directly inside this template. + +**Instead, you will create your app normally, and then "inject" the magic folder into it.** + +--- + +## 🛠️ How to Start a New Project + +**1. Scaffold your new website** +Open your terminal and generate your new app (for example, a Vite React app). + +```bash +pnpm create vite@latest my-new-site -- --template react +cd my-new-site +pnpm install +``` + +**2. Download this template** +Open your file explorer, or use another terminal, and clone this template to your computer: + +```bash +git clone [https://git.pynixworld.com/Moody6/node-app-builder-template.git](https://git.pynixworld.com/Moody6/node-app-builder-template.git) +``` + +**3. Inject the Magic** +Open the `node-app-builder-template` folder you just downloaded. Copy the hidden `.gitea` folder, and paste it directly into the _root_ your new `my-new-site` folder. +_(Important: The `.gitea` folder must sit right next to your `package.json` file!)_ + +**4. Connect to the Server** +Go to the Gitea website and create a brand new, empty repository. Then, go back to your `my-new-site` terminal and run these commands to link them: + +```bash +git init +git checkout -b dev # We always start in the Dev environment! +git remote add origin [https://git.pynixworld.com/YOUR_USERNAME/YOUR_NEW_REPO.git](https://git.pynixworld.com/YOUR_USERNAME/YOUR_NEW_REPO.git) +``` + +**5. Launch It!** +Add your files, commit, and push. The server will take over from here. + +```bash +git add . +git commit -m "Initial commit with deployment magic" +git push -u origin dev +``` + +_(Wait about 15 seconds, then check https://builder.pynixworld.com!)_ + +--- ## 🌍 The Two Worlds (Environments) -This repository uses **Branches** to decide where your website goes. +This pipeline uses **Branches** to decide where your website goes. - 🛠️ **The `dev` branch (Staging):** Pushing to this branch sends your site to [https://builder.pynixworld.com](https://builder.pynixworld.com). This is your playground. Break things, test new colors, and experiment here! - 🌟 **The `main` branch (Production):** Pushing to this branch sends your site to [https://www.pynixworld.com](https://www.pynixworld.com). This is your official, live portfolio for the world to see. ---- - -## 💻 How to Get Started - -**1. Clone this repository to your computer** - -```bash -git clone [https://git.pynixworld.com/Moody6/node-app-builder-template.git](https://git.pynixworld.com/Moody6/node-app-builder-template.git) -cd node-app-builder-template -``` - -**2. Switch to your playground branch** -Always do your messy work here first! - -```bash -git checkout -b dev -``` - -**3. Install the packages** -(We recommend `pnpm` because it is super fast!) - -```bash -pnpm install -``` - -**4. Start coding** -Run the local server to see your changes live on your computer as you type: - -```bash -pnpm run dev -``` - ---- - -## 🚀 How to Put Your Site on the Internet - -When you are ready to see your site on your actual domain name, just commit and push! - -**To update the Test Site (`builder.pynixworld.com`):** - -```bash -git add . -git commit -m "Added a cool new button" -git push origin dev -``` - -_(Wait about 15 seconds, then refresh your browser!)_ - -**To update the Live Site (`www.pynixworld.com`):** -When your test site looks perfect, merge your code into the main branch to show the world. +To push to production, just merge your `dev` branch into `main` and push! ```bash git checkout main @@ -70,7 +71,7 @@ git push origin main ## 🧰 Changing Frameworks? -This template is ready for **React, SvelteKit, Vue, or Astro** right out of the box. +This pipeline is set for **React, SvelteKit, Vue, or Astro** right out of the box. If you decide to try a different framework like Create React App, Next.js, or SvelteKit, you just need to tell the server which folder to look for.