generated from realAscot/template-python
workflow
This commit is contained in:
parent
82b19a5185
commit
e960ceb1dd
23
LICENSE
Normal file
23
LICENSE
Normal file
@ -0,0 +1,23 @@
|
||||
MIT License with Attribution Requirement
|
||||
|
||||
Copyright (c) 2025 Adam Skotarczak <adam@skotarczak.net>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the “Software”), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, subject to the following conditions:
|
||||
|
||||
1. The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
2. **Attribution Requirement**: Any public use or distribution of this Software,
|
||||
modified or unmodified, must include a clear and visible attribution to the original author:
|
||||
|
||||
**Adam Skotarczak <adam@skotarczak.net>**
|
||||
|
||||
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
||||
PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
|
||||
FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
||||
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
30
README.md
30
README.md
@ -1,9 +1,11 @@
|
||||
# Python Bootstrap-Flask-Template mit `.venv`- und `.env` Support
|
||||
# Python Bootstrap-Flask-Template mit LOGGING - `.venv`- und `.env` Support
|
||||
|
||||

|
||||
|
||||
> ⚙️ Dieses Projekt verwendet [Git Subtree](SUBTREE.md) zur Integration des Basis-Templates. Details siehe [`SUBTREE.md`](SUBTREE.md).
|
||||
|
||||
> **DIESES DOKUMENT BEFINDET SICH IN DER ENTWICKLUNG UND IST UNVOLLSTÄNDIG UND FALSCH**
|
||||
|
||||
Dieses Template nutzt PEP 8, Type Hints, Docstrings und einen vordefinierten Workspace für sauberen Python-Code.
|
||||
Außerdem bietet es ein portables Start-Template für Python-Anwendungen mit folgenden Features:
|
||||
|
||||
@ -14,6 +16,7 @@ Außerdem bietet es ein portables Start-Template für Python-Anwendungen mit fol
|
||||
- Sauberer Einstiegspunkt über `run.py`
|
||||
- Keine systemweiten Python-Pakete notwendig
|
||||
- Logging-Utils bereits integriert
|
||||
- Flask integration und Template Management
|
||||
|
||||
Das Template ist durchdacht, pragmatisch und stark auf Entwicklerkomfort ausgelegt.
|
||||
Es bietet eine sehr gute Grundlage für Projekte aller Art – insbesondere CLI-Tools, kleine Services und lokale Anwendungen. Die automatische Einrichtung der virtuellen Umgebung hebt es funktional deutlich von Standard-Vorlagen ab.
|
||||
@ -23,17 +26,20 @@ Es bietet eine sehr gute Grundlage für Projekte aller Art – insbesondere CLI-
|
||||
- [ ] [pep-518](https://peps.python.org/pep-0518/)-konform 🚫
|
||||
|
||||
> ⚠️ Dieses Template verfolgt kein komplexes Build-System.
|
||||
Es ist dafür gedacht, dir in Sekunden eine saubere, gekapselte Python-Umgebung bereitzustellen – perfekt zum schnellen Testen, Debuggen oder Projektstart.
|
||||
Einfach deinen Code in main.py werfen, bei Bedarf requirements.txt anpassen, run.py starten – fertig. Kein Setup-Wahnsinn, kein Overhead.
|
||||
Es ist dafür gedacht, dir in Sekunden eine saubere, gekapselte Python-Umgebung bereitzustellen – perfekt zum schnellen Testen, Debuggen oder Projektstart. Insbesondere für Webapps mit Flask und Visualisierung.
|
||||
|
||||
- [x] Einfach deinen Code in main.py werfen, bei Bedarf `requirements.txt` anpassen, `run.py` starten, Flask konfigurieren [PLATZHALTER] und – fertig. Kein Setup-Wahnsinn, kein Overhead!
|
||||
|
||||
---
|
||||
|
||||
## 🔜 Inhalt der Readme
|
||||
## 📑 Inhalt der Readme
|
||||
|
||||
- [Python Bootstrap-Flask-Template mit `.venv`- und `.env` Support](#python-bootstrap-flask-template-mit-venv--und-env-support)
|
||||
- [🔜 Inhalt der Readme](#-inhalt-der-readme)
|
||||
- [🔧 Projektstruktur](#-projektstruktur)
|
||||
- [Python Bootstrap-Flask-Template mit LOGGING - `.venv`- und `.env` Support](#python-bootstrap-flask-template-mit-logging---venv--und-env-support)
|
||||
- [📑 Inhalt der Readme](#-inhalt-der-readme)
|
||||
- [🔧 Projektstruktur \[IN BEARBEITUNG\]](#-projektstruktur-in-bearbeitung)
|
||||
- [🚀 Erste Schritte](#-erste-schritte)
|
||||
- [Flask Server konfigurieren](#flask-server-konfigurieren)
|
||||
- [Der erste Start](#der-erste-start)
|
||||
- [Beim ersten Start passiert:](#beim-ersten-start-passiert)
|
||||
- [📦 Abhängigkeiten](#-abhängigkeiten)
|
||||
- [⚙️ .env-Datei (optional)](#️-env-datei-optional)
|
||||
@ -50,7 +56,7 @@ Einfach deinen Code in main.py werfen, bei Bedarf requirements.txt anpassen, run
|
||||
|
||||
---
|
||||
|
||||
## 🔧 Projektstruktur
|
||||
## 🔧 Projektstruktur [IN BEARBEITUNG]
|
||||
|
||||
```plaintext
|
||||
|
||||
@ -86,6 +92,10 @@ Einfach deinen Code in main.py werfen, bei Bedarf requirements.txt anpassen, run
|
||||
- [ ] `requirements.txt` auf deine Bedürfnisse anpassen.
|
||||
- [ ] `media/`Verzeichnis Löschen falls vorhanden.
|
||||
|
||||
### Flask Server konfigurieren
|
||||
|
||||
### Der erste Start
|
||||
|
||||
**Erster Start des Templates:**
|
||||
|
||||
```bash
|
||||
@ -98,7 +108,8 @@ python run.py
|
||||
2. `requirements.txt` wird installiert
|
||||
3. Das Skript wird automatisch innerhalb der venv neu gestartet
|
||||
4. `.env` wird geladen (falls vorhanden)
|
||||
5. **Die App startet 🚀**
|
||||
5. Flask Server startet
|
||||
6. **Die App startet 🚀**
|
||||
|
||||
> Es erfolgen einige Ausgaben, die alle aus der `main.py` stammen, außer du `DEBUG` in der `.env` aktiviert hast.
|
||||
|
||||
@ -112,6 +123,7 @@ Alle Abhängigkeiten werden aus `requirements.txt` installiert.
|
||||
**Beispiel:**
|
||||
|
||||
```text
|
||||
flask
|
||||
python-dotenv
|
||||
```
|
||||
|
||||
|
0
app/routes.py
Normal file
0
app/routes.py
Normal file
0
app/templates/config.html
Normal file
0
app/templates/config.html
Normal file
0
app/templates/index.html
Normal file
0
app/templates/index.html
Normal file
Loading…
x
Reference in New Issue
Block a user