Merge pull request 'fix: hartcodierte Repo-Pfade durch portable Alternativen ersetzen' (#17) from fix/hartcodierte-pfade into main
This commit was merged in pull request #17.
This commit is contained in:
@@ -11,11 +11,11 @@ Dieses Repository enthält die globale Claude-Code-Workflow-Konfiguration für a
|
|||||||
### Neuer Rechner (2 Schritte)
|
### Neuer Rechner (2 Schritte)
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://gitea.troeger-net.org/martin/claude-workflow.git /mnt/projekte/claude-workflow
|
git clone https://gitea.troeger-net.org/martin/claude-workflow.git <pfad>
|
||||||
/mnt/projekte/claude-workflow/bootstrap.sh
|
<pfad>/bootstrap.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
Das Bootstrap-Skript erstellt alle Symlinks, prueft Voraussetzungen und zeigt fehlende Installationsbefehle an.
|
Der Pfad ist frei wählbar. Das Bootstrap-Skript erstellt alle Symlinks, prueft Voraussetzungen und zeigt fehlende Installationsbefehle an.
|
||||||
|
|
||||||
### Voraussetzungen
|
### Voraussetzungen
|
||||||
|
|
||||||
@@ -40,13 +40,13 @@ echo 'DEIN_TOKEN' > ~/.config/gitea/token && chmod 600 ~/.config/gitea/token
|
|||||||
|
|
||||||
**Pushen (Rechner 1):**
|
**Pushen (Rechner 1):**
|
||||||
```bash
|
```bash
|
||||||
cd /mnt/projekte/claude-workflow
|
cd <repo-pfad>
|
||||||
git add -p && git commit -m "..." && git push
|
git add -p && git commit -m "..." && git push
|
||||||
```
|
```
|
||||||
|
|
||||||
**Übernehmen (Rechner 2):**
|
**Übernehmen (Rechner 2):**
|
||||||
```bash
|
```bash
|
||||||
cd /mnt/projekte/claude-workflow && git pull
|
cd <repo-pfad> && git pull
|
||||||
```
|
```
|
||||||
|
|
||||||
Da alles über Symlinks verbunden ist, sind Änderungen sofort aktiv.
|
Da alles über Symlinks verbunden ist, sind Änderungen sofort aktiv.
|
||||||
|
|||||||
@@ -7,8 +7,8 @@ Enthält Skills (`/go`, `/ship`, `/story`, `/plan-review`, `/workflow-review`),
|
|||||||
## Einrichtung
|
## Einrichtung
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://gitea.troeger-net.org/martin/claude-workflow.git /mnt/projekte/claude-workflow
|
git clone https://gitea.troeger-net.org/martin/claude-workflow.git <pfad>
|
||||||
/mnt/projekte/claude-workflow/bootstrap.sh
|
<pfad>/bootstrap.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
Weitere Details in `CLAUDE.md`.
|
Weitere Details in `CLAUDE.md`.
|
||||||
|
|||||||
+3
-2
@@ -1,7 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
REPO="/mnt/projekte/claude-workflow"
|
REPO="$(cd "$(dirname "$0")" && pwd)"
|
||||||
|
|
||||||
echo "=== Claude-Workflow Bootstrap ==="
|
echo "=== Claude-Workflow Bootstrap ==="
|
||||||
|
|
||||||
@@ -27,8 +27,9 @@ ln -sf "$REPO/dotfiles/gitea-mcp-wrapper.sh" ~/.claude/gitea-mcp-wrapper.sh
|
|||||||
chmod +x "$REPO/dotfiles/gitea-mcp-wrapper.sh"
|
chmod +x "$REPO/dotfiles/gitea-mcp-wrapper.sh"
|
||||||
echo " Dotfiles verlinkt"
|
echo " Dotfiles verlinkt"
|
||||||
|
|
||||||
|
ln -sfn "$REPO/hooks" ~/.claude/hooks
|
||||||
chmod +x "$REPO/hooks/"*.sh
|
chmod +x "$REPO/hooks/"*.sh
|
||||||
echo " Hooks ausfuehrbar"
|
echo " Hooks verlinkt und ausfuehrbar"
|
||||||
|
|
||||||
# --- Voraussetzungen pruefen ---
|
# --- Voraussetzungen pruefen ---
|
||||||
|
|
||||||
|
|||||||
@@ -70,7 +70,7 @@
|
|||||||
"hooks": [
|
"hooks": [
|
||||||
{
|
{
|
||||||
"type": "command",
|
"type": "command",
|
||||||
"command": "bash /mnt/projekte/claude-workflow/hooks/pre-bash-checks.sh",
|
"command": "bash ~/.claude/hooks/pre-bash-checks.sh",
|
||||||
"statusMessage": "Prüfe Bash-Sicherheitsregeln..."
|
"statusMessage": "Prüfe Bash-Sicherheitsregeln..."
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
@@ -82,7 +82,7 @@
|
|||||||
"hooks": [
|
"hooks": [
|
||||||
{
|
{
|
||||||
"type": "command",
|
"type": "command",
|
||||||
"command": "bash /mnt/projekte/claude-workflow/hooks/auto-format.sh"
|
"command": "bash ~/.claude/hooks/auto-format.sh"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -92,7 +92,7 @@
|
|||||||
"hooks": [
|
"hooks": [
|
||||||
{
|
{
|
||||||
"type": "command",
|
"type": "command",
|
||||||
"command": "bash /mnt/projekte/claude-workflow/hooks/verify-on-stop.sh"
|
"command": "bash ~/.claude/hooks/verify-on-stop.sh"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,8 @@
|
|||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
# Dateiname aus Umgebungsvariable (Claude Code setzt CLAUDE_TOOL_INPUT_FILE_PATH)
|
REPO_ROOT="$(dirname "$(cd "$(dirname "$(readlink -f "$0")")" && pwd)")"
|
||||||
|
|
||||||
FILE="${CLAUDE_TOOL_INPUT_FILE_PATH:-}"
|
FILE="${CLAUDE_TOOL_INPUT_FILE_PATH:-}"
|
||||||
|
|
||||||
if [[ -z "$FILE" || ! -f "$FILE" ]]; then
|
if [[ -z "$FILE" || ! -f "$FILE" ]]; then
|
||||||
@@ -39,7 +40,7 @@ case "$EXT" in
|
|||||||
# Zweiter Pass: räumt die nun verwaisten Mehrfach-Leerzeilen auf (MD012).
|
# Zweiter Pass: räumt die nun verwaisten Mehrfach-Leerzeilen auf (MD012).
|
||||||
for _ in 1 2; do
|
for _ in 1 2; do
|
||||||
markdownlint-cli2 \
|
markdownlint-cli2 \
|
||||||
--config /mnt/projekte/claude-workflow/.markdownlint-cli2.jsonc \
|
--config "$REPO_ROOT/.markdownlint-cli2.jsonc" \
|
||||||
--fix "$FILE" >/dev/null 2>&1 || true
|
--fix "$FILE" >/dev/null 2>&1 || true
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user