snapshot-push
Push bonbon-ai outer repo as full snapshot, including be/ and fe/ content
How do I install this agent skill?
npx skills add https://github.com/rheinmir/setup --skill snapshot-pushIs this agent skill safe to install?
- Gen Agent Trust Hubpass
The skill automates repository snapshots by executing a local bash script. It uses a hardcoded local filesystem path and passes user-provided text directly to the shell script as an argument, which could be exploited for command injection if the script handles the input unsafely.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
What does this agent skill do?
Skill: snapshot-push
WHAT
Purpose và context
- Purpose: Push toàn bộ outer repo
bonbon-ailên GitLab như một snapshot — kể cả content củabe/vàfe/(các sub-repos có.gitriêng). Dùng scriptscripts/snapshot-push.shđể tự động hide/restore.gitdirs. - Trigger (when to use): "push snapshot", "snapshot push", "đẩy snapshot", "push outer repo".
- Non-goals: không push riêng từng sub-repo
be//fe/, không áp dụng cho repo khác ngoàibonbon-ai.
Mental model
repo root bonbon-ai → snapshot-push.sh (hide .git của be/ fe/ → commit + push → restore .git) → commit hash + số files changed.
Input và output contract
| Field | Required? | Ý nghĩa | |
|---|---|---|---|
| In | message | không | commit message tuỳ chọn, truyền cho script |
| Out | kết quả push | có | commit hash + số files changed báo cho user |
Rules và capabilities
- RULE-01 (MUST): Verify đang ở đúng repo root (
/Volumes/giatbhSSD(APFS)/workspace/bonbon-ai) trước khi chạy script. - Capabilities: đọc/ghi git của outer repo qua script có sẵn; ghi remote GitLab (push).
Failure boundaries
- Không ở đúng repo root → blocked, không chạy script.
- Script lỗi (push fail) → failed, báo nguyên output lỗi cho user.
HOW
Main workflow
| Step | Type | Inputs | Action | Outputs/exit | Failure/next |
|---|---|---|---|---|---|
| W01 | deterministic | cwd | Verify repo root | đúng root | sai → blocked |
| W02 | effect | message | Chạy script snapshot-push | commit + push | lỗi → failed |
| W03 | deterministic | output script | Report commit hash + số files changed | báo cáo | — |
Chi tiết từng bước (nguồn chân lý cho W01–W03):
- Verify đang ở đúng repo root (
/Volumes/giatbhSSD(APFS)/workspace/bonbon-ai) - Chạy:
bash scripts/snapshot-push.sh "<optional message>" - Report kết quả: commit hash + số files changed
Branches
Không có nhánh phụ trong version này.
Validation và stopping
Thành công = script trả rc 0 và in commit hash. Không retry tự động khi push lỗi.
Examples
- Positive: "đẩy snapshot" tại
/Volumes/giatbhSSD(APFS)/workspace/bonbon-ai→bash scripts/snapshot-push.sh "snapshot"→ báo commit hash + số files changed, gồm cả file trongbe/vàfe/. - Boundary/failure: gọi khi cwd là
be/→ W01 thấy không phải repo root → dừng, báo user chuyển về root, không chạy script.
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/rheinmir/setup/snapshot-push">View snapshot-push on skillZs</a>