| name | looply-git-guardrails |
| description | Use to verify safety of git operations during active looply workflows. Blocks destructive commands and suggests safe alternatives. |
Use this skill when the user explicitly invokes $looply-git-guardrails, asks to run /looply:git-guardrails, or when git destructive operations are detected during active workflows.
Quick usage:
$looply-git-guardrails [git-command]
Primary references:
- Workflow playbook: ../../../../.looply/state/workflow-playbook.opencode.md
- Host status contract: ../../../../.looply/state/host-status-contract.json
- Project context: ../../../../.looply/custom/project-context.md
- Session context: ../../../../.looply/custom/session-context.md
- Session links: ../../../../.looply/custom/session-links.json
Usage:
- Explicit mention:
$looply-git-guardrails
- Workflow alias to honor:
/looply:git-guardrails
- Syntax in Codex:
$looply-git-guardrails [git-command]
Example:
- $looply-git-guardrails "push --force origin main"
When to use:
- Before running destructive git commands (push --force, hard reset, rebase -i, --no-verify)
- During active workflows to verify if git operations are safe
- To audit the current git state and compliance with project conventions
Curated example guidance:
- ICL mode:
on
- Use examples only for style, structure and quality calibration.
- Do not copy feature-specific names, identifiers or business details from examples.
- No example was selected for this workflow.
Git Guardrails
Blocked Commands
The following commands are blocked during active workflows:
| Command | Risk | Alternative |
|---|
push --force | Overwrites remote history | push --force-with-lease |
hard reset | Loses uncommitted changes | stash + reset --soft |
rebase -i | Rewrites history interactively | regular rebase + separate commits |
commit --no-verify | Skips pre-commit hooks | Fix hook issues |
checkout --force | Overwrites local changes | stash before checkout |
branch -D | Deletes unmerged branch | branch -d (with check) |
Security Policy
- Never run
push --force on the main branch (main/master).
- Never run
hard reset or rebase -i with an active workflow without first committing or stashing.
- Always check for unmerged branches before deleting.
- Respect the project's commit convention (see project-conventions).
- Never use
--no-verify unless the user explicitly requests it.
- Before any destructive operation, check
.looply/custom/features/ for active workflows.
Behavior
When called without arguments, audits the current git state:
- Current branch and status
- Uncommitted changes
- Active workflows that would be impacted
- Compliance with commit conventions
When called with a specific git command, evaluates the safety of the operation.
Execution rules:
- Start by reading the workflow playbook and checking for active features.
- If the user asked for help, explain syntax, arguments, example, expected output and next step without mutating state.
- Check
.looply/custom/features/ for active workflows before authorizing destructive git operations.
- Never execute blocked commands without explicit user override.
- Always suggest a safer alternative when blocking a command.
- Use managed pack files as canonical process definition and write local state only under
.looply/custom.
- Respond in the same language as the user's input.
- For existing projects, use the real local codebase as the primary source of truth and use context files only as accelerators.
- Follow balanced interaction mode to avoid unnecessary repeated clarifications.
- Keep the response visually structured with clear Markdown section titles.
- Do not use emojis.
Composed Agent Context
The sections below were pre-composed by looply from agent context_slots.
Constraints
- Never run push --force on the main branch
- Block destructive operations during active workflows
- Always suggest a safe alternative
Escalation
- Escalate git conflicts to delivery-orchestrator
- Escalate branching strategy questions to architect
Arguments:
- git-command: git command to be verified (optional; if omitted, audits current state)