Git-Status Endpoint mit Outgoing-Commits und Dashboard-Badges
- GET /api/sessions/{id}/git-status: Parsed git status --porcelain in add/edit/delete Listen
- Outgoing-Commits: Zählt unpushed Commits via git rev-list --count @{u}..HEAD
- Dashboard: Zeigt Git-Badges asynchron pro Session (+N, ~N, -N, ↑N)
- CSS: Farbige Badges (grün=add, orange=edit, rot=delete, blau=outgoing)
This commit is contained in:
1 parent
166465fd54
commit
ac150af4c5
4 files changed
+195
No files matched your search
@@ -131,6 +131,12 @@ async function apiGetChain(chainId) {
|
||||
return resp.json();
|
||||
}
|
||||
|
||||
async function apiGitStatus(sessionId) {
|
||||
const resp = await fetch(`/api/sessions/${sessionId}/git-status`);
|
||||
if (!resp.ok) return null;
|
||||
return resp.json();
|
||||
}
|
||||
|
||||
async function apiBackupDb() {
|
||||
const resp = await fetch('/api/backup', { method: 'POST' });
|
||||
if (!resp.ok) throw new Error('Backup fehlgeschlagen');
|
||||
|
||||
Reference in new issue
Block a user