Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .claude/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@
"Skill(sentry-skills:agents-md)",
"Skill(sentry-skills:brand-guidelines)",
"Skill(sentry-skills:doc-coauthoring)",
"Skill(sentry-skills:security-review)"
"Skill(sentry-skills:security-review)",
"Skill(sentry-skills:django-perf-review)"
],
"deny": []
},
Expand Down
163 changes: 85 additions & 78 deletions plugins/sentry-skills/skills/claude-settings-audit/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,28 +18,29 @@ find . -maxdepth 2 \( -name "*.toml" -o -name "*.json" -o -name "*.lock" -o -nam

Check for these indicator files:

| Category | Files to Check |
|----------|---------------|
| **Python** | `pyproject.toml`, `setup.py`, `requirements.txt`, `Pipfile`, `poetry.lock`, `uv.lock` |
| **Node.js** | `package.json`, `package-lock.json`, `yarn.lock`, `pnpm-lock.yaml` |
| **Go** | `go.mod`, `go.sum` |
| **Rust** | `Cargo.toml`, `Cargo.lock` |
| **Ruby** | `Gemfile`, `Gemfile.lock` |
| **Java** | `pom.xml`, `build.gradle`, `build.gradle.kts` |
| **Build** | `Makefile`, `Dockerfile`, `docker-compose.yml` |
| **Infra** | `*.tf` files, `kubernetes/`, `helm/` |
| **Monorepo** | `lerna.json`, `nx.json`, `turbo.json`, `pnpm-workspace.yaml` |
| Category | Files to Check |
| ------------ | ------------------------------------------------------------------------------------- |
| **Python** | `pyproject.toml`, `setup.py`, `requirements.txt`, `Pipfile`, `poetry.lock`, `uv.lock` |
| **Node.js** | `package.json`, `package-lock.json`, `yarn.lock`, `pnpm-lock.yaml` |
| **Go** | `go.mod`, `go.sum` |
| **Rust** | `Cargo.toml`, `Cargo.lock` |
| **Ruby** | `Gemfile`, `Gemfile.lock` |
| **Java** | `pom.xml`, `build.gradle`, `build.gradle.kts` |
| **Build** | `Makefile`, `Dockerfile`, `docker-compose.yml` |
| **Infra** | `*.tf` files, `kubernetes/`, `helm/` |
| **Monorepo** | `lerna.json`, `nx.json`, `turbo.json`, `pnpm-workspace.yaml` |

## Phase 2: Detect Services

Check for service integrations:

| Service | Detection |
|---------|-----------|
| Service | Detection |
| ---------- | ------------------------------------------------------------------------------- |
| **Sentry** | `sentry-sdk` in deps, `@sentry/*` packages, `.sentryclirc`, `sentry.properties` |
| **Linear** | Linear config files, `.linear/` directory |
| **Linear** | Linear config files, `.linear/` directory |

Read dependency files to identify frameworks:

- `package.json` → check `dependencies` and `devDependencies`
- `pyproject.toml` → check `[project.dependencies]` or `[tool.poetry.dependencies]`
- `Gemfile` → check gem names
Expand Down Expand Up @@ -98,42 +99,42 @@ Only include commands for tools actually detected in the project.

#### Python (if any Python files or config detected)

| If Detected | Add These Commands |
|-------------|-------------------|
| Any Python | `python --version`, `python3 --version` |
| `poetry.lock` | `poetry show`, `poetry env info` |
| `uv.lock` | `uv pip list`, `uv tree` |
| `Pipfile.lock` | `pipenv graph` |
| `requirements.txt` (no other lock) | `pip list`, `pip show`, `pip freeze` |
| If Detected | Add These Commands |
| ---------------------------------- | --------------------------------------- |
| Any Python | `python --version`, `python3 --version` |
| `poetry.lock` | `poetry show`, `poetry env info` |
| `uv.lock` | `uv pip list`, `uv tree` |
| `Pipfile.lock` | `pipenv graph` |
| `requirements.txt` (no other lock) | `pip list`, `pip show`, `pip freeze` |

#### Node.js (if package.json detected)

| If Detected | Add These Commands |
|-------------|-------------------|
| Any Node.js | `node --version` |
| `pnpm-lock.yaml` | `pnpm list`, `pnpm why` |
| `yarn.lock` | `yarn list`, `yarn info`, `yarn why` |
| `package-lock.json` | `npm list`, `npm view`, `npm outdated` |
| TypeScript (`tsconfig.json`) | `tsc --version` |
| If Detected | Add These Commands |
| ---------------------------- | -------------------------------------- |
| Any Node.js | `node --version` |
| `pnpm-lock.yaml` | `pnpm list`, `pnpm why` |
| `yarn.lock` | `yarn list`, `yarn info`, `yarn why` |
| `package-lock.json` | `npm list`, `npm view`, `npm outdated` |
| TypeScript (`tsconfig.json`) | `tsc --version` |

#### Other Languages

| If Detected | Add These Commands |
|-------------|-------------------|
| `go.mod` | `go version`, `go list`, `go mod graph`, `go env` |
| `Cargo.toml` | `rustc --version`, `cargo --version`, `cargo tree`, `cargo metadata` |
| `Gemfile` | `ruby --version`, `bundle list`, `bundle show` |
| `pom.xml` | `java --version`, `mvn --version`, `mvn dependency:tree` |
| `build.gradle` | `java --version`, `gradle --version`, `gradle dependencies` |
| If Detected | Add These Commands |
| -------------- | -------------------------------------------------------------------- |
| `go.mod` | `go version`, `go list`, `go mod graph`, `go env` |
| `Cargo.toml` | `rustc --version`, `cargo --version`, `cargo tree`, `cargo metadata` |
| `Gemfile` | `ruby --version`, `bundle list`, `bundle show` |
| `pom.xml` | `java --version`, `mvn --version`, `mvn dependency:tree` |
| `build.gradle` | `java --version`, `gradle --version`, `gradle dependencies` |

#### Build Tools

| If Detected | Add These Commands |
|-------------|-------------------|
| `Dockerfile` | `docker --version`, `docker ps`, `docker images` |
| `docker-compose.yml` | `docker-compose ps`, `docker-compose config` |
| `*.tf` files | `terraform --version`, `terraform providers`, `terraform state list` |
| `Makefile` | `make --version`, `make -n` |
| If Detected | Add These Commands |
| -------------------- | -------------------------------------------------------------------- |
| `Dockerfile` | `docker --version`, `docker ps`, `docker images` |
| `docker-compose.yml` | `docker-compose ps`, `docker-compose config` |
| `*.tf` files | `terraform --version`, `terraform providers`, `terraform state list` |
| `Makefile` | `make --version`, `make -n` |

### Skills (for Sentry Projects)

Expand All @@ -150,13 +151,15 @@ If this is a Sentry project (or sentry-skills plugin is installed), include:
"Skill(sentry-skills:agents-md)",
"Skill(sentry-skills:brand-guidelines)",
"Skill(sentry-skills:doc-coauthoring)",
"Skill(sentry-skills:security-review)"
"Skill(sentry-skills:security-review)",
"Skill(sentry-skills:django-perf-review)"
]
```

### WebFetch Domains

#### Always Include (Sentry Projects)

```json
[
"WebFetch(domain:docs.sentry.io)",
Expand All @@ -168,21 +171,21 @@ If this is a Sentry project (or sentry-skills plugin is installed), include:

#### Framework-Specific

| If Detected | Add Domains |
|-------------|-------------|
| **Django** | `docs.djangoproject.com` |
| **Flask** | `flask.palletsprojects.com` |
| **FastAPI** | `fastapi.tiangolo.com` |
| **React** | `react.dev` |
| **Next.js** | `nextjs.org` |
| **Vue** | `vuejs.org` |
| **Express** | `expressjs.com` |
| **Rails** | `guides.rubyonrails.org`, `api.rubyonrails.org` |
| **Go** | `pkg.go.dev` |
| **Rust** | `docs.rs`, `doc.rust-lang.org` |
| **Docker** | `docs.docker.com` |
| **Kubernetes** | `kubernetes.io` |
| **Terraform** | `registry.terraform.io` |
| If Detected | Add Domains |
| -------------- | ----------------------------------------------- |
| **Django** | `docs.djangoproject.com` |
| **Flask** | `flask.palletsprojects.com` |
| **FastAPI** | `fastapi.tiangolo.com` |
| **React** | `react.dev` |
| **Next.js** | `nextjs.org` |
| **Vue** | `vuejs.org` |
| **Express** | `expressjs.com` |
| **Rails** | `guides.rubyonrails.org`, `api.rubyonrails.org` |
| **Go** | `pkg.go.dev` |
| **Rust** | `docs.rs`, `doc.rust-lang.org` |
| **Docker** | `docs.docker.com` |
| **Kubernetes** | `kubernetes.io` |
| **Terraform** | `registry.terraform.io` |

### MCP Server Suggestions

Expand All @@ -195,6 +198,7 @@ cat .mcp.json 2>/dev/null || echo "No existing .mcp.json"
#### Sentry MCP (if Sentry SDK detected)

Add to `.mcp.json` (replace `{org-slug}` and `{project-slug}` with your Sentry organization and project slugs):

```json
{
"mcpServers": {
Expand All @@ -209,6 +213,7 @@ Add to `.mcp.json` (replace `{org-slug}` and `{project-slug}` with your Sentry o
#### Linear MCP (if Linear usage detected)

Add to `.mcp.json`:

```json
{
"mcpServers": {
Expand Down Expand Up @@ -239,24 +244,24 @@ Example output structure:
```markdown
## Detected Tech Stack

| Category | Found |
|----------|-------|
| Languages | Python 3.x |
| Package Manager | poetry |
| Frameworks | Django, Celery |
| Services | Sentry |
| Build Tools | Docker, Make |
| Category | Found |
| --------------- | -------------- |
| Languages | Python 3.x |
| Package Manager | poetry |
| Frameworks | Django, Celery |
| Services | Sentry |
| Build Tools | Docker, Make |

## Recommended .claude/settings.json

\`\`\`json
{
"permissions": {
"allow": [
// ... grouped by category with comments
],
"deny": []
}
"permissions": {
"allow": [
// ... grouped by category with comments
],
"deny": []
}
}
\`\`\`

Expand All @@ -268,12 +273,14 @@ If you use Sentry or Linear, add the MCP config to `.mcp.json`...
## Important Rules

### What to Include

- Only READ-ONLY commands that cannot modify state
- Only tools that are actually used by the project (detected via lock files)
- Standard system commands (ls, cat, find, etc.)
- The `:*` suffix allows any arguments to the base command

### What to NEVER Include

- **Absolute paths** - Never include user-specific paths like `/home/user/scripts/foo` or `/Users/name/bin/bar`
- **Custom scripts** - Never include project scripts that may have side effects (e.g., `./scripts/deploy.sh`)
- **Alternative package managers** - If the project uses pnpm, do NOT include npm/yarn commands
Expand All @@ -283,13 +290,13 @@ If you use Sentry or Linear, add the MCP config to `.mcp.json`...

Only include the package manager actually used by the project:

| If Detected | Include | Do NOT Include |
|-------------|---------|----------------|
| `pnpm-lock.yaml` | pnpm commands | npm, yarn |
| `yarn.lock` | yarn commands | npm, pnpm |
| `package-lock.json` | npm commands | yarn, pnpm |
| `poetry.lock` | poetry commands | pip (unless also has requirements.txt) |
| `uv.lock` | uv commands | pip, poetry |
| `Pipfile.lock` | pipenv commands | pip, poetry |
| If Detected | Include | Do NOT Include |
| ------------------- | --------------- | -------------------------------------- |
| `pnpm-lock.yaml` | pnpm commands | npm, yarn |
| `yarn.lock` | yarn commands | npm, pnpm |
| `package-lock.json` | npm commands | yarn, pnpm |
| `poetry.lock` | poetry commands | pip (unless also has requirements.txt) |
| `uv.lock` | uv commands | pip, poetry |
| `Pipfile.lock` | pipenv commands | pip, poetry |

If multiple lock files exist, include only the commands for each detected manager.
4 changes: 4 additions & 0 deletions plugins/sentry-skills/skills/django-perf-review/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Apache License 2.0

This skill contains original content.
See repository root LICENSE for full terms.
Loading