Tags: Marking What Matters
A real lightweight tag. A real, fully annotated release. Genuinely different objects.
A tag marks one specific real commit as meaningful, permanently — a beta milestone, a release, a point worth coming back to by name instead of by hash. git supports two genuinely different kinds: a real lightweight tag, which is nothing more than a named pointer exactly like a branch (just one that never moves), and a real annotated tag, which is its own actual object in the database — with a tagger, a date, and a real message, the same way a commit has an author and a message.\n\nv0.9-beta marks a real earlier milestone as a plain, lightweight pointer. v1.0.0, the real first stable release, gets the fully annotated treatment — because a release genuinely deserves a recorded reason, not just a name.
A Real Lightweight Tag
git tag v0.9-beta HEAD~3
Nothing but a real, named pointer at a specific commit — structurally identical to a branch, except it is never meant to move.
A Real, Fully Annotated Tag
git tag -a v1.0.0 -m "Version 1.0.0 - first stable release"
This creates a genuine, separate tag object in the database — with its own real tagger, date, and message — which then points at the commit. git show v1.0.0 displays both layers: the tag's own real message, then the commit it points to.
The Real Difference, Confirmed Directly
cat .git/refs/tags/v0.9-beta # a plain commit hash
cat .git/refs/tags/v1.0.0 # a DIFFERENT hash — the real tag object, not the commit
A lightweight tag's ref file contains the commit's own hash directly. An annotated tag's ref file contains the hash of the real tag object instead — genuinely one more layer of indirection.
Sharing Real Tags
git push origin v0.9-beta v1.0.0
Tags are not included in a plain git push by default — they need to be pushed explicitly (or with --tags for all of them at once).
Lightweight tag
A real, named pointer directly at a commit — structurally the same as a branch, just one that is never meant to move. Confirmed directly in this lab: its ref file contains the commit's own hash.
Annotated tag
A genuine, separate object in git's database, with its own real tagger, date, and message, which then points at a commit. Confirmed directly in this lab: its ref file contains a different hash than the commit itself — the tag object's own hash.
🏷️ A Real Lightweight Tag
Mark an earlier real milestone with a plain, named pointer.
cd ~/team-recipes && git tag v0.9-beta HEAD~3cd ~/team-recipes && git show v0.9-betacd ~/team-recipes && cat .git/refs/tags/v0.9-betastudent@lab:~$ cd ~/team-recipes && git tag v0.9-beta HEAD~3 student@lab:~$ cd ~/team-recipes && git show v0.9-beta commit 179d7d8b7f4307fa91f4c65614f459d48544da92 (tag: v0.9-beta) Author: Ada Lovelace <ada@example.com> Date: Fri Jan 2 21:50:00 2026 +0000 Add slow cooker chili recipe diff --git a/slow-cooker-chili.md b/slow-cooker-chili.md new file mode 100644 index 0000000..ebbcf0c --- /dev/null +++ b/slow-cooker-chili.md @@ -0,0 +1,3 @@ +Slow Cooker Chili + +Brown beef, add beans and tomatoes, simmer 6 hours. student@lab:~$ cd ~/team-recipes && cat .git/refs/tags/v0.9-beta 179d7d8b7f4307fa91f4c65614f459d48544da92
🎖️ A Real Annotated Release
The genuine first stable release deserves a recorded reason.
cd ~/team-recipes && git tag -a v1.0.0 -m 'Version 1.0.0 - first stable release of the team recipe collection'cd ~/team-recipes && git show v1.0.0student@lab:~$ cd ~/team-recipes && git tag -a v1.0.0 -m 'Version 1.0.0 - first stable release of the team recipe collection' student@lab:~$ cd ~/team-recipes && git show v1.0.0 tag v1.0.0 Tagger: Ada Lovelace <ada@example.com> Date: Mon Aug 24 19:38:36 2026 +0000 Version 1.0.0 - first stable release of the team recipe collection commit 85b4a6eeccd4d5babcb20db3c458b39c1850bf09 (HEAD -> master, tag: v1.0.0) Author: Ada Lovelace <ada@example.com> Date: Fri Jan 2 23:00:00 2026 +0000 Add freezer audit tip diff --git a/kitchen-tips.md b/kitchen-tips.md index 38071bb..63bb331 100644 --- a/kitchen-tips.md +++ b/kitchen-tips.md @@ -5,3 +5,5 @@ Preheat the oven before starting any bake recipe. Always preheat for at least 12 minutes before baking (see PR #142 for the oven latency testing behind this number). Let meat rest 5 minutes after cooking before slicing. + +Audit the freezer quarterly for freezer burn.
🔬 The Real Difference, Confirmed
One ref file holds a commit hash. The other holds something else entirely.
cd ~/team-recipes && cat .git/refs/tags/v1.0.0cd ~/team-recipes && git cat-file -p v1.0.0student@lab:~$ cd ~/team-recipes && cat .git/refs/tags/v1.0.0 4317c73bd869433a413219324e0c3017216fcb76 student@lab:~$ cd ~/team-recipes && git cat-file -p v1.0.0 object 85b4a6eeccd4d5babcb20db3c458b39c1850bf09 type commit tag v1.0.0 tagger Ada Lovelace <ada@example.com> 1787600316 +0000 Version 1.0.0 - first stable release of the team recipe collection
📤 Push the Real Tags
Tags need to be shared explicitly.
cd ~/team-recipes && git push origin v0.9-beta v1.0.0student@lab:~$ cd ~/team-recipes && git push origin v0.9-beta v1.0.0 Enumerating objects: 345, done. Counting objects: 100% (345/345), done. Compressing objects: 100% (140/140), done. Writing objects: 100% (344/344), 31.40 KiB | 297.00 KiB/s, done. Total 344 (delta 120), reused 331 (delta 112), pack-reused 0 remote: Resolving deltas: 100% (120/120), done. To ../recipes-origin.git * [new tag] v0.9-beta -> v0.9-beta * [new tag] v1.0.0 -> v1.0.0
Lab 3.5.1 complete. A real lightweight tag and a real annotated release, genuinely different, both shared:\n\n\n v0.9-beta (lightweight): ✅ plain pointer\n v1.0.0 (annotated) : ✅ real, separate tag object\n Both pushed : ✅ on the remote\n
Enable JavaScript to run the live terminal and track your progress.