ShadCN Implementation
This commit is contained in:
80
README.md
80
README.md
@@ -1,12 +1,84 @@
|
||||
# Django Port Workspace
|
||||
|
||||
This folder contains the rewrite target for the current FastAPI + React application.
|
||||
It is intended to be self-contained.
|
||||
|
||||
## What is here
|
||||
|
||||
- [`backend`](/home/sandy/HUB-master/django-port/backend): Django project and domain apps
|
||||
- [`frontend`](/home/sandy/HUB-master/django-port/frontend): SvelteKit frontend prepared for `shadcn-svelte`
|
||||
- [`docs/port-plan.md`](/home/sandy/HUB-master/django-port/docs/port-plan.md): migration strategy and scope
|
||||
- [`backend`](backend): Django project and domain apps
|
||||
- [`frontend`](frontend): SvelteKit frontend with a local manual shadcn-style component layer
|
||||
- [`data/legacy`](data/legacy): bundled legacy SQLite sources used by `import_legacy_data`
|
||||
- [`docs/port-plan.md`](docs/port-plan.md): migration strategy and scope
|
||||
|
||||
## Self-contained data
|
||||
|
||||
The folder already contains:
|
||||
|
||||
- the live Django database at [`backend/db.sqlite3`](backend/db.sqlite3)
|
||||
- the bundled legacy import sources at [`data/legacy/cincin_phase1.sqlite`](data/legacy/cincin_phase1.sqlite) and [`data/legacy/dalcorso.sqlite`](data/legacy/dalcorso.sqlite)
|
||||
|
||||
That means `django-port` no longer depends on the repo-root legacy databases for normal use or for re-running the importer.
|
||||
|
||||
## Fresh Machine Setup
|
||||
|
||||
`django-port` is now structured so it can be pushed as its own repository and used without the rest of the original workspace.
|
||||
|
||||
Backend setup:
|
||||
|
||||
```bash
|
||||
cd backend
|
||||
python3 -m venv .venv
|
||||
source .venv/bin/activate
|
||||
pip install -e .
|
||||
cp .env.example .env
|
||||
python manage.py migrate
|
||||
python manage.py runserver
|
||||
```
|
||||
|
||||
Frontend setup:
|
||||
|
||||
```bash
|
||||
cd frontend
|
||||
npm install
|
||||
cp .env.example .env
|
||||
npm run dev
|
||||
```
|
||||
|
||||
Default local URLs:
|
||||
|
||||
- frontend: `http://localhost:5173`
|
||||
- backend API: `http://localhost:8000/api`
|
||||
|
||||
## Pushing As Its Own Repo
|
||||
|
||||
If this folder is moved into a new repository, include at minimum:
|
||||
|
||||
- `backend/`
|
||||
- `frontend/`
|
||||
- `data/legacy/`
|
||||
- `docs/`
|
||||
- `.gitignore`
|
||||
- `README.md`
|
||||
|
||||
If you want the seeded app data on the destination machine, commit and push:
|
||||
|
||||
- [`backend/db.sqlite3`](backend/db.sqlite3)
|
||||
- [`data/legacy/cincin_phase1.sqlite`](data/legacy/cincin_phase1.sqlite)
|
||||
- [`data/legacy/dalcorso.sqlite`](data/legacy/dalcorso.sqlite)
|
||||
|
||||
The repo does not need to include:
|
||||
|
||||
- any files outside `django-port`
|
||||
- a local virtualenv
|
||||
- `frontend/node_modules`
|
||||
- `frontend/.svelte-kit`
|
||||
|
||||
## Environment Files
|
||||
|
||||
Example env files are included at:
|
||||
|
||||
- [`backend/.env.example`](backend/.env.example)
|
||||
- [`frontend/.env.example`](frontend/.env.example)
|
||||
|
||||
## What is intentionally not done
|
||||
|
||||
@@ -14,4 +86,4 @@ This folder contains the rewrite target for the current FastAPI + React applicat
|
||||
- No Svelte or Django bootstrapping commands
|
||||
- No heavy build, dev-server, or migration runs
|
||||
|
||||
Everything committed here is code and structure only.
|
||||
Everything needed for the port itself now lives under this folder.
|
||||
|
||||
Reference in New Issue
Block a user