This file provides instructions and context for the Gemini AI model.

Project Overview

This is a Jekyll-based static website for the Fresno Grape Stake Yard. It uses the minima theme.

Key Technologies

  • Ruby: The programming language used by Jekyll. The required version is 3.2.4.
  • Jekyll: A static site generator. This project uses the github-pages gem.
  • minima: The Jekyll theme used for this project.
  • Tinysearch: A lightweight, client-side search engine.
  • Pandoc: A universal document converter, used to generate the search index.
  • just: A command runner, used to define and run project-specific commands.

Project Structure

  • _config.yml: Jekyll configuration file.
  • _includes/: Reusable HTML components.
  • _layouts/: HTML templates for pages.
  • _pages/: The main content of the website, written in Markdown.
  • _sass/: SCSS files for styling.
  • assets/: Images, CSS, and other assets.
  • Gemfile: Ruby dependencies.
  • justfile: Defines commands for building, serving, and updating the project.
  • generate_tinysearch_index.sh: A script that uses pandoc and tinysearch to create a search index for the site.

Development Workflow

Setup

  1. Install Ruby 3.2.4. rvm or chruby can be used for this.
  2. Install bundler: gem install bundler.
  3. Install dependencies: bundle install.

Running the local server

Use the just command:

just serve

This will run bundle exec jekyll serve.

Updating dependencies

Use the just command:

just update

This will run bundle update.

The search functionality is powered by tinysearch. The search index is generated by the generate_tinysearch_index.sh script. This script:

  1. Uses pandoc to convert the content of the _pages directory to plain text.
  2. Combines the plain text content into a JSON file (tmp/tinysearch.json).
  3. Uses tinysearch to create the search index from the JSON file.

CI/CD

The project uses GitHub Actions for CI/CD:

  • codeql-analysis.yml: Runs CodeQL analysis on the master branch to find security vulnerabilities.
  • update-dependencies.yml: Manually triggered workflow to update Ruby dependencies and commit the Gemfile.lock file.

Content Style

  • Markdown Formatting: In Markdown files, use line-break delimited sentences. Each sentence should be on its own line to improve diff readability.