chore: install-git-hooks.ps1 for Windows
This commit is contained in:
@@ -6,20 +6,29 @@
|
||||
|
||||
Один раз после clone:
|
||||
|
||||
**Linux / Git Bash:**
|
||||
```bash
|
||||
./contrib/install-git-hooks.sh
|
||||
```
|
||||
|
||||
**Windows (PowerShell):**
|
||||
```powershell
|
||||
.\contrib\install-git-hooks.ps1
|
||||
```
|
||||
|
||||
При коммите, если изменились **`version.txt`**, **`SSH_MONITOR_VERSION`** в `ssh-monitor` или любой из агентских файлов (`ssh-monitor`, `*.sh` из списка manifest), **pre-commit** вызовет `contrib/manifest/generate.py` и добавит `release/manifest-{версия}.json` в коммит.
|
||||
|
||||
## Ручная генерация (локально)
|
||||
|
||||
Скрипт **`.local/build-release-manifest.sh`** создаётся `install-git-hooks.sh` и **не коммитится** (см. `.gitignore`).
|
||||
Скрипты **`.local/build-release-manifest.ps1`** (Windows) и **`.local/build-release-manifest.sh`** (Git Bash) создаются установщиком и **не коммитятся** (см. `.gitignore`).
|
||||
|
||||
```powershell
|
||||
.\.local\build-release-manifest.ps1
|
||||
.\.local\build-release-manifest.ps1 2.2.3-SAC
|
||||
```
|
||||
|
||||
```bash
|
||||
./.local/build-release-manifest.sh
|
||||
./.local/build-release-manifest.sh 2.2.3-SAC
|
||||
git add release/manifest-2.2.3-SAC.json
|
||||
```
|
||||
|
||||
Ядро генерации в репозитории: `contrib/manifest/generate.py` (используется hook и локальным wrapper).
|
||||
|
||||
Reference in New Issue
Block a user