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
71 changes: 47 additions & 24 deletions .claude/commands/ticket.md
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
---
description: Work on a JIRA/Linear ticket end-to-end
allowed-tools: Read, Write, Edit, Glob, Grep, Bash(git:*), Bash(gh:*), Bash(npm:*), mcp__jira__*, mcp__github__*, mcp__linear__*
description: Work on a GitHub Issue end-to-end
allowed-tools: Read, Write, Edit, Glob, Grep, Bash(git:*), Bash(gh:*), Bash(npm:*), mcp__github__*
---

# Ticket Workflow
# GitHub Issue Workflow

Work on ticket: $ARGUMENTS
Work on issue: $ARGUMENTS

## Instructions

### 1. Read the Ticket
### 1. Read the Issue

First, fetch and understand the ticket:
First, fetch and understand the GitHub Issue:

```
Use the JIRA/Linear MCP tools to:
- Get ticket details (title, description, acceptance criteria)
- Check linked tickets or epics
- Review any comments or attachments
Use the GitHub MCP tools or CLI to:
- Get issue details (title, description, labels)
- Check linked issues or milestones
- Review any comments
- Check acceptance criteria in the issue body
```

Summarize:
Expand All @@ -35,7 +36,8 @@ Before coding:
### 3. Create a Branch

```bash
git checkout -b {initials}/{ticket-id}-{brief-description}
git checkout -b {initials}/{issue-number}-{brief-description}
# Example: git checkout -b jd/42-add-user-auth
```

### 4. Implement the Changes
Expand All @@ -44,37 +46,39 @@ git checkout -b {initials}/{ticket-id}-{brief-description}
- Write tests first (TDD)
- Make incremental commits

### 5. Update the Ticket
### 5. Update the Issue

As you work:
- Add comments with progress updates
- Update status (In Progress → In Review)
- Update labels if needed (in-progress, needs-review)
- Log any blockers or questions

### 6. Create PR and Link

When ready:
- Create PR with `gh pr create`
- Link the PR to the ticket
- Add ticket ID to PR title: `feat(PROJ-123): description`
- Reference the issue in the PR body: `Closes #<issue-number>`
- PR title format: `feat(#42): description` or `fix(#42): description`

### 7. If You Find a Bug

If you discover an unrelated bug while working:
1. Create a new ticket with details
2. Link it to the current ticket if related
1. Create a new issue with details
2. Link it to the current issue if related
3. Note it in the PR description
4. Continue with original task

## Example Workflow

```
Me: /ticket PROJ-123
Me: /ticket 42

Claude:
1. Fetching PROJ-123 from JIRA...
1. Fetching Issue #42 from GitHub...
Title: Add user profile avatar upload
Description: Users should be able to upload a profile picture...
Labels: enhancement, frontend

Acceptance Criteria:
- [ ] Upload button on profile page
- [ ] Support JPG/PNG up to 5MB
Expand All @@ -84,13 +88,32 @@ Claude:
Found: src/screens/Profile/ProfileScreen.tsx
Found: src/components/Avatar/Avatar.tsx

3. Creating branch: cw/PROJ-123-avatar-upload
3. Creating branch: cw/42-avatar-upload

4. [Implements feature with TDD approach]

5. Updating JIRA status to "In Review"...
Adding comment: "Implementation complete, PR ready for review"
5. Adding comment to Issue #42: "Implementation complete, PR ready for review"

6. Creating PR and linking to PROJ-123...
PR #456 created: feat(PROJ-123): add avatar upload to profile
6. Creating PR and linking to Issue #42...
PR #56 created: feat(#42): add avatar upload to profile
Body includes: Closes #42
```

## GitHub Issue Commands Reference

```bash
# View issue details
gh issue view 42

# List issues assigned to you
gh issue list --assignee @me

# Add comment to issue
gh issue comment 42 --body "Progress update: ..."

# Add label to issue
gh issue edit 42 --add-label "in-progress"

# Create linked PR
gh pr create --title "feat(#42): description" --body "Closes #42"
```
97 changes: 97 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
{
"name": "Claudia Development Container",
"image": "mcr.microsoft.com/devcontainers/typescript-node:1-20-bullseye",
"features": {
"ghcr.io/devcontainers/features/docker-in-docker:2": {},
"ghcr.io/devcontainers/features/git:1": {},
"ghcr.io/devcontainers/features/github-cli:1": {},
"ghcr.io/devcontainers-contrib/features/curl-apt-get:1": {}
},
"forwardPorts": [3000, 8080, 8081, 8384, 11434],
"portsAttributes": {
"3000": {
"label": "Application",
"onAutoForward": "notify"
},
"8080": {
"label": "SearXNG",
"onAutoForward": "silent"
},
"8081": {
"label": "SurrealDB",
"onAutoForward": "silent"
},
"8384": {
"label": "Serena",
"onAutoForward": "silent"
},
"11434": {
"label": "Ollama",
"onAutoForward": "silent"
}
},
"postCreateCommand": "npm install || true && docker compose -f docker-compose.dev.yml up -d",
"postStartCommand": "docker compose -f docker-compose.dev.yml start",
"postAttachCommand": "echo '🚀 Development environment ready!'",
"customizations": {
"vscode": {
"extensions": [
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode",
"ms-vscode.vscode-typescript-next",
"GitHub.copilot",
"GitHub.copilot-chat",
"GitHub.vscode-pull-request-github",
"eamodio.gitlens",
"bradlc.vscode-tailwindcss",
"ZixuanChen.vitest-explorer",
"ms-azuretools.vscode-docker"
],
"settings": {
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"typescript.preferences.importModuleSpecifier": "relative",
"typescript.updateImportsOnFileMove.enabled": "always",
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[typescriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"github.copilot.enable": {
"*": true,
"yaml": true,
"markdown": true,
"plaintext": false
},
"terminal.integrated.defaultProfile.linux": "bash"
}
},
"codespaces": {
"openFiles": ["README.md", "CLAUDE.md"]
}
},
"remoteEnv": {
"NODE_ENV": "development",
"OLLAMA_HOST": "http://localhost:11434",
"SEARXNG_HOST": "http://localhost:8080",
"SURREALDB_HOST": "http://localhost:8081"
},
"containerEnv": {
"TZ": "UTC"
},
"hostRequirements": {
"cpus": 4,
"memory": "8gb",
"storage": "32gb"
}
}
38 changes: 38 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# GitHub Token (required for GitHub MCP)
GITHUB_TOKEN=ghp_your-github-personal-access-token

# Serena MCP Configuration
SERENA_HOST=http://localhost:8384
SERENA_API_KEY=your-serena-api-key

# Context7 MCP Configuration
CONTEXT7_API_KEY=your-context7-api-key

# SurrealDB Configuration (Docker local)
SURREALDB_URL=http://localhost:8081
SURREALDB_USER=root
SURREALDB_PASS=root
SURREALDB_NS=claudia
SURREALDB_DB=main
SURREALDB_ROOT_PASSWORD=root

# SearXNG Configuration (Docker local)
SEARXNG_URL=http://localhost:8080
SEARXNG_SECRET_KEY=generate-a-random-secret-key-here

# Ollama Configuration (Docker local)
OLLAMA_HOST=http://localhost:11434

# Sentry Configuration (optional)
SENTRY_AUTH_TOKEN=your-sentry-auth-token
SENTRY_ORG=your-sentry-org

# Slack Configuration (optional)
SLACK_BOT_TOKEN=xoxb-your-slack-bot-token
SLACK_TEAM_ID=T00000000

# Codecov (optional for CI)
CODECOV_TOKEN=your-codecov-token

# Semgrep (optional for security scanning)
SEMGREP_APP_TOKEN=your-semgrep-token
50 changes: 50 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# GitHub Copilot Instructions

## Project Context
This is a Claude Code project configuration showcase demonstrating best practices for AI-assisted development.

## Code Style Guidelines
- Use TypeScript strict mode
- Prefer `interface` over `type` for object shapes
- Use `unknown` instead of `any`
- Write self-documenting code with meaningful names
- Follow the single responsibility principle

## Patterns to Follow
- Use early returns to reduce nesting
- Prefer composition over inheritance
- Handle all error cases explicitly
- Always include loading, error, and empty states in UI
- Use factory functions for test mocks

## Testing Conventions
- Write tests using Jest
- Follow TDD: write failing test first
- Use AAA pattern: Arrange, Act, Assert
- Mock factory pattern: `getMockUser(overrides)`

## React Patterns
- Use functional components with hooks
- Prefer custom hooks for reusable logic
- Always handle loading and error states
- Use proper TypeScript generics for components

## Git Conventions
- Branch naming: `{initials}/{issue-number}-{description}`
- Commit format: Conventional Commits (`feat:`, `fix:`, `docs:`)
- Reference issues in PR body: `Closes #<issue-number>`

## MCP Servers Available
- GitHub: Issue tracking and repository management
- Serena: AI agent integration
- Context7: Context retrieval
- SurrealDB: Database operations
- SearXNG: Web search
- Ollama: Local LLM inference

## Do Not
- Use `any` type
- Swallow errors silently
- Commit secrets or credentials
- Skip error handling
- Use outdated patterns
45 changes: 45 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
version: 2
updates:
# NPM dependencies
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
timezone: "UTC"
open-pull-requests-limit: 10
commit-message:
prefix: "chore(deps)"
labels:
- "dependencies"
- "automated"
groups:
dev-dependencies:
dependency-type: "development"
update-types:
- "minor"
- "patch"
production-dependencies:
dependency-type: "production"
update-types:
- "patch"

# GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
timezone: "UTC"
open-pull-requests-limit: 5
commit-message:
prefix: "chore(ci)"
labels:
- "ci"
- "automated"
groups:
actions:
patterns:
- "*"
Loading
Loading