Skip to main content

Getting Started

Get SigmaShake running in your project in under 5 minutes.

Installation

curl -fsSL https://sigmashake.com/install | sh

This downloads the ssg binary for your platform and adds it to your PATH.

Via npm

npm install -g @sigmashake/ssg

From source

git clone https://github.com/sigmashake/sigmashake-mono.git
cd sigmashake-mono/sigmashake-gov
bun install
bun build --compile src/cli.ts --outfile ssg

Initialize your project

Run ssg init in your project root:

cd your-project
ssg init

This creates:

  • .sigmashake/rules/ — Directory for your governance rules
  • A starter ruleset with common safety rules (destructive commands, secret files, etc.)

Write your first rule

Create .sigmashake/rules/my_rules.rules:

rule block-force-push {
priority 100
severity error
DENY execution
IF command CONTAINS "git push --force"
OR command CONTAINS "git push -f"
MESSAGE "Force push is not allowed. Use --force-with-lease instead."
}

Test it

echo '{"tool":"Bash","input":{"command":"git push --force origin main"}}' | ssg eval

Output:

{
"decision": "block",
"rule_id": "block-force-push",
"reason": "Force push is not allowed. Use --force-with-lease instead."
}

Start the dashboard

ssg serve

Opens the governance dashboard at http://localhost:5599 with:

  • Real-time audit log
  • Pending approval queue (for ASK decisions)
  • Rule viewer
  • Performance metrics

Integrate with Claude Code

ssg init --client claude-code

This installs a PreToolUse hook in .claude/hooks/ssg-check.sh that automatically evaluates every tool call before execution.

Validate your rules

ssg lint

Checks all .rules files for syntax errors, undefined fields, and invalid patterns.

Next steps