🚀 NEUE FEATURES: Push-to-Gitea, Inotify-Watcher, Changelog mit git log
docker-build-and-push / build (push) Successful in 1m54s

This commit is contained in:
KI-Sparringpartner
2026-08-03 17:23:50 +02:00
parent b390d90061
commit 9161abae63
6 changed files with 187 additions and 66 deletions
+13 -3
View File
@@ -109,8 +109,13 @@ def unsubscribe_repo(project_name: str, projects_dir: Path):
return {"success": False, "error": f"Konnte nicht loeschen: {e}"}
def push_changes(repo_path: Path, message: str = "Update 🧠"):
"""Pusht lokale Änderungen ins Repository."""
def push_changes(repo_path: Path, message: str = "Update 🧠", changelog_content: str = None):
"""Pusht lokale Änderungen ins Repository mit optionalem Changelog-Content."""
# Optional: Changelog aktualisieren
if changelog_content:
changelog_path = repo_path / "CHANGELOG.md"
changelog_path.write_text(changelog_content)
result = subprocess.run(
["git", "add", "."], cwd=repo_path, capture_output=True, text=True
)
@@ -118,8 +123,13 @@ def push_changes(repo_path: Path, message: str = "Update 🧠"):
if result.returncode != 0:
return {"success": False, "error": f"git add fehlgeschlagen: {result.stderr}"}
# Commit message mit optionaler Info aus Changelog
commit_msg = message
if changelog_content:
commit_msg += "\n\nChangelog aktualisiert"
result = subprocess.run(
["git", "commit", "-m", message], cwd=repo_path, capture_output=True, text=True
["git", "commit", "-m", commit_msg], cwd=repo_path, capture_output=True, text=True
)
if result.returncode != 0 and "nothing to commit" not in result.stderr.lower():