# CLAUDE.md — CloudCaptain

## Project Quick Reference

**CloudCaptain** is an open-source learning platform for Cloud, DevOps, AI, and Operations built with Docusaurus 3 and deployed to GitHub Pages.

```bash
cd website
npm install         # Install dependencies
npm start           # Dev server at localhost:3000
npm run build       # Production build
npm run serve       # Serve production build locally
```

> For full project intelligence (architecture, brand colors, content guidelines), see [`website/CLAUDE.md`](website/CLAUDE.md).

### Curriculum (from-scratch lessons at /learn)

Lessons live in `curriculum/phases/NN-phase/NN-lesson/` (docs, runnable code with tests, quiz, artifacts) and are served by a second Docusaurus docs instance at `/learn`. `scripts/build-curriculum.mjs` validates every lesson against [`LESSON_TEMPLATE.md`](LESSON_TEMPLATE.md) and generates the sidebar and stats before each start/build. See [`AGENTS.md`](AGENTS.md) for the repo map and commands.

```bash
cd website
npm run curriculum:validate                      # validate all lessons (fast)
npm run curriculum:scaffold -- 05-containers image-layers --type Learn --langs python --title "..."
npm run curriculum:test -- containers/process-isolation
npm run curriculum:unit                          # generator unit tests
```

---

## AI Contribution Log

Features built with Claude Code assistance:

### feature/lessons-progress-cleanup (2026-10-31)
- Six new lessons (`setup/lab-doctor`, `linux/pid1-supervisor`, `containers/image-layers`, `containers/registry-pull`, `iac/state-reconciler`, `aiops/mcp-kubectl-server`) with tests, quizzes, artifacts and one `code/smoke.sh` each, run on Ubuntu + Docker + OpenTofu + kind by `lesson-smoke.yml`; new AIOps learning path
- Lesson-aware Captain's Bridge (telemetry cell, Lesson rail tab, completion toast), `/progress` Curriculum section, "Build this from scratch" cards on reference docs, progress export v2, Commands-tab extractor fix
- 15 stub/pointer pages deleted with redirects (`website/redirects.json`), Interview Prep sidebar refs, honest category counts, hero CTA → /learn, homepage "Learn from scratch" section
- Freshness system: `curriculum/versions.json` (+ `versions-weekly.yml`), `curriculum/deprecations.json`, `<ToolVersion/>`, `--deprecations` scan, 18 Reference-doc status notes; issue templates, nightly validation + link check

### feature/curriculum-scaffold (2026-10-31)
- `curriculum/` with manifest (phases 00–16), JSON Schemas, `LESSON_TEMPLATE.md`, `AGENTS.md`, `ROADMAP.md`, `CHANGELOG.md`
- `scripts/build-curriculum.mjs` validator/generator (+ `--scaffold`, `--roadmap`, `--json`), `run-lesson-tests.mjs`, node:test suite
- Second docs instance at `/learn`, front-matter injection from `lesson.json`, `<Quiz/>`, `<ShipIt/>`, `<RunTests/>`, `<CurriculumHome/>`, `<LearningPath/>` components
- First lesson: Containers → Process Isolation (Python + Bash, 11 tests, quiz, prompt + skill artifacts)

### fix/broken-commands-and-claims (2026-10-31)
- Fixed commands that no longer worked (Actions pins, apt-key, dead Helm repo, kubectl --record, old registries), flagged retired tech (ingress-nginx, PSP, CodeCommit, Swarm, Terraform BUSL), corrected README/homepage numbers, unlisted stub pages

### design/homepage-v2-upgrade
- Animated typing terminal with character-by-character command rendering
- Scroll-reveal animations on all sections using IntersectionObserver
- Count-up animation on stats numbers when scrolled into view
- Enhanced glassmorphism cards with gradient borders and glow effects
- Rotating gradient ring on founder photo, animated floating orbs
- Live GitHub stats (stars, contributors, forks) fetched from GitHub API
- Connected steps in How It Works with gradient lines and icon circles
- Overhauled light mode with blue-tinted backgrounds, card shadows, gradient titles
- Button shimmer, badge pulse glow, and timeline hover effects
- Navbar spacing fixes, removed Blog link, fixed title truncation

### feature/json-data-extraction
- Extracted all homepage section data to 8 JSON files in `website/src/data/`
- Hidden Testimonials section (component preserved for future use)
- Updated README, CONTRIBUTING.md, and contribute page with JSON data guide
- Career paths data also extracted to JSON

### Data Files Created
| File | Content |
|------|---------|
| `categories.json` | 12 technology category cards |
| `learningPaths.json` | 3 learning path cards |
| `testimonials.json` | Testimonial entries (hidden) |
| `howItWorks.json` | 4 process steps |
| `sponsors.json` | Sponsor tier configuration |
| `contributeActions.json` | 5 contribution types |
| `techBadges.json` | 11 tech badge names |
| `careerPaths.json` | Career path definitions |

---

## Claude Code Setup Guide

### Prerequisites
- Node.js 22+
- npm
- [Claude Code CLI](https://docs.anthropic.com/en/docs/claude-code)

### Getting Started

```bash
# Clone the repo
git clone https://github.com/nomadicmehul/CloudCaptain.git
cd CloudCaptain

# Install and run
cd website
npm install
npm start
```

### Useful Prompts

When working on this project with Claude Code, these prompts work well:

- **Add a new technology category**: "Add a new category for [tool] to `website/src/data/categories.json`"
- **Update homepage content**: "Update the learning paths in `website/src/data/learningPaths.json`"
- **Fix styling issues**: "Fix the [component] styling in `website/src/pages/index.tsx`"
- **Add documentation**: "Create a new doc page for [topic] under `website/docs/tools/`"
- **Build and verify**: "Run `npm run build` in the website directory and fix any errors"

### Commit Guidelines

- **NEVER include `Co-Authored-By` lines in commit messages** — this is strictly prohibited
- Do not add any AI attribution tags or trailers to commits
- Use imperative mood: `Add: ...`, `Update: ...`, `Fix: ...`
- Run `npm run build` before submitting a PR

### Project Context

Claude Code automatically reads `CLAUDE.md` files. This project has two:

- **`/CLAUDE.md`** (this file) — contribution log and setup guide
- **`/website/CLAUDE.md`** — detailed project intelligence (architecture, brand colors, directory structure, content guidelines)

Both files are picked up automatically when Claude Code is run from the repo root or the `website/` directory.
