Contributor Guide
Welcome to the Carlisle Scouts website team! This guide walks you through setting up your computer and making updates to our site.
What You Need
- A GitHub account — sign up free at github.com
- Git for Windows — download from git-scm.com (use default install options)
- VS Code — download from code.visualstudio.com
- That’s it — Hugo (the tool that builds the site) is already included in the repo
One-Time Setup
1. Get Added to the Repository
Ask the scoutmaster or current site admin to add your GitHub username as a collaborator on the repo. You’ll get an email invite — accept it.
2. Configure Git
Open a terminal (PowerShell or VS Code terminal) and set your name and email:
git config --global user.name "Your Name"
git config --global user.email "you@example.com"
3. Clone the Repository
cd ~\source\repos # or wherever you keep projects
git clone https://github.com/CarlisleScouts/carlislescouts-org.git
cd carlislescouts-org
Git will ask you to sign in to GitHub the first time.
4. Open the Project in VS Code
code .
Or: open VS Code → File → Open Folder → select the carlislescouts-org folder.
Making Changes
Every change follows the same pattern: branch → edit → preview → commit → push → pull request.
Step 1: Start Fresh
Make sure you’re on main and have the latest code:
git checkout main
git pull
Step 2: Create a Branch
Name it after what you’re working on:
git checkout -b add-summer-camp-post
Some good naming examples:
update-calendar-pageadd-hiking-trip-photosfix-typo-contact-page
Step 3: Make Your Edits
Content files live in the content/ folder. Most updates will be:
- New posts — create a file in
content/posts/(copy an existing post as a template) - Page updates — edit the existing
.mdfile - Images — add to
static/img/your-post-name/and reference as/img/your-post-name/filename.jpg
Post Frontmatter Template
Every post starts with frontmatter between --- markers:
---
title: My New Post Title
date: 2026-04-15
draft: false
tags: ["camping", "hiking"]
author: Your Name
---
Your content goes here...
After your opening paragraph(s), place the summary marker on its own line:
<!--more-->
Everything above the marker appears as the summary on the home page. Everything below it is only visible when you click through to the full post.
Rest of the post that only shows on the full page...
Set draft: true while you’re still working on it. Change to false when it’s ready.
Step 4: Preview Locally
In VS Code, open the terminal and run:
.\scripts\Start-HugoServe.ps1
Then open http://localhost:1313 in your browser. The page auto-refreshes as you save changes. Press Ctrl+C in the terminal to stop the server.
To include draft posts in the preview:
.\scripts\Start-HugoServe.ps1 -Drafts
Step 5: Commit Your Changes
git add .
git commit -m "Add summer camp post with photos"
Write a short message describing what you changed.
Step 6: Push Your Branch
git push -u origin add-summer-camp-post
(Use whatever you named your branch in Step 2.)
Step 7: Open a Pull Request
Still untested…
- Go to github.com/CarlisleScouts/carlislescouts-org
- You’ll see a yellow banner: “add-summer-camp-post had recent pushes — Compare & pull request” — click it
- Add a title and short description of your changes
- Click Create pull request
An admin will review your changes, might leave comments, and will merge it when everything looks good. Once merged, the site updates automatically.
Quick Reference
| Task | Command |
|---|---|
| Get latest code | git checkout main then git pull |
| Create a branch | git checkout -b branch-name |
| See what changed | git status |
| Stage all changes | git add . |
| Commit | git commit -m "description" |
| Push | git push -u origin branch-name |
| Preview site | .\scripts\Start-HugoServe.ps1 |
| Preview with drafts | .\scripts\Start-HugoServe.ps1 -Drafts |
Where Things Live
| What | Where |
|---|---|
| Blog posts | content/posts/ |
| Parent info pages | content/ForParents/ |
| Scout info pages | content/ForScouts/ |
| Eagle Scout pages | content/TrailToEagle/ |
| Images | static/img/ |
| Downloadable files | static/files/ |
Tips
- Copy an existing post when creating a new one — it’s the easiest way to get the format right
- Keep image file sizes reasonable — resize large photos before adding them (under 500 KB is ideal)
- One topic per branch — don’t mix unrelated changes in the same pull request
- Ask questions — it’s totally fine to ask for help in your pull request comments