Your First Change
Time to ship something. In this walkthrough you’ll add a tiny page to the app, see it working on your own machine, commit it, and then watch it go live on the shared dev site at dev.hackleyclubz.org.
Before starting, make sure you’ve finished Setting Up Your Dev Environment.
How our branches work
devis the shared development branch. Everyone on the team commits here, and every push automatically deploys to https://dev.hackleyclubz.org within about a minute.mainis production (https://hackleyclubz.org). It’s protected — nobody pushes to it directly. When dev is ready, Lilly reviews and merges dev into main.
So: you work on dev, and your work shows up on the dev site. Simple.
1. Start from the latest dev
In your hackley-clubz folder:
git checkout dev
git pull
Always git pull before you start working — other people are committing to
dev too, and you want their latest changes.
2. Create your hello page
We keep a www/helloworld/ directory where every new developer adds a page
as their first change. Create a file named after yourself. For example, if
your name is Jerry, create www/helloworld/jerry.php containing:
<?php
echo "Hi Jerry";
That’s the whole file. Use your own name for both the filename and the message (hardcoded is fine — that’s the point of the exercise).
3. Test it locally
With your local server running (cd www && php -S localhost:8000), open:
http://localhost:8000/helloworld/jerry.php
You should see Hi Jerry. This is the golden rule of working on this project: always see your change working locally before you commit it.
4. Commit and push
git add www/helloworld/jerry.php
git commit -m "Add hello world page for Jerry"
git push
If git push is rejected because someone else pushed while you were
working, run git pull and then git push again.
5. See it live
Pushing to dev triggers an automatic deploy. Wait about a minute, then
open:
https://dev.hackleyclubz.org/helloworld/jerry.php
That’s your code, running on a real server on the internet. Welcome to the team. 🎉
Ground rules for working on dev
- Test locally before you commit. Never push something you haven’t seen work.
- Pull before you start, and before you push. The
devbranch is shared. - Never commit secrets —
config.local.php, anything inkeys/, or any passwords/API keys. The servers have their own copies. - If you break the dev site, fix it or say so right away. Every push redeploys, so dev heals as fast as you can push — but don’t leave it broken silently.
- Don’t touch
main. Getting changes into production is Lilly’s job — she reviews what’s on dev and merges it into main.
