CLAUDE.md

CLAUDE.md

This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.

Project Overview

This is a Jekyll-based Norwegian food blog called “Pappaperm” that runs on GitHub Pages. The site features recipes, cooking tips, and food-related content with a custom theme and responsive design.

Architecture

  • Jekyll Static Site Generator: Uses Jekyll 4.2.2 with custom theme
  • Docker-based Development: All operations run through Docker containers
  • Content Structure:
    • _posts/: Blog posts with recipes and articles
    • _my_categories/: Custom category definitions (bakverk, dessert, drikke, etc.)
    • _my_tags/: Tag definitions for content organization
    • _layouts/: Page templates (default, post, category_index, tag_index)
    • _includes/: Reusable template components
    • assets/: Images, CSS (SCSS), and JavaScript files

Development Commands

All commands should be run through the provided shell scripts that use Docker. All scripts automatically install dependencies if needed:

Local Development

  • ./view.sh - Start development server with live reload at http://localhost:4000
  • rake view (inside container) - Alternative way to start development server

Building

  • ./build.sh - Build production site
  • rake build (inside container) - Build for production
  • rake build_for_test (inside container) - Build for testing with strict front matter

Testing

  • ./test.sh - Run markdown linting and Jekyll tests
  • rake test (inside container) - Run local tests (Jekyll doctor + HTML-Proofer)
  • rake ci (inside container) - Run CI tests (build + test)

Maintenance

  • ./clean.sh - Clean generated site files
  • ./update.sh - Update dependencies and Docker images
  • rake clean (inside container) - Clean generated site files

Docker Operations

  • ./jekyll.sh "command" - Run any Jekyll command in Docker container
  • Uses Jekyll 4.2.2 image with --platform linux/amd64 for Apple Silicon compatibility
  • All scripts include automatic bundle install when dependencies are missing

Content Guidelines

  • Posts use YAML front matter with categories and tags
  • Images stored in assets/img/ with thumbnails in assets/img/thumbs/
  • Categories and tags are defined in _my_categories/ and _my_tags/ collections
  • Norwegian language content with UTF-8 encoding

Key Configuration

  • Site runs on Docker with Jekyll 4.2.2
  • Production URL: https://pappaperm.com
  • Uses Kramdown for markdown processing
  • SCSS compilation with compression
  • Pagination set to 24 posts per page
  • SEO and sitemap plugins enabled