Skip to content

Commit 9504dc5

Browse files
author
GitHub Workshop Bot
committed
Canonicalize podcast file naming (ep## -> canonical group prefixes)
All source podcast scripts, transcripts, bundles, manifest, and generated companion HTML now use canonical filenames from docs/EPISODE_MAP.json: - podcasts/scripts/{chapters,appendices}: 58 .txt files renamed (ch-, ref-, tools-, git-, a11y-, agents-, sec-) - podcasts/transcripts/{chapters,appendices}: 116 .json files renamed (-chapters/-segments preserved) - podcasts/bundles/: 58 markdown bundles regenerated with canonical names - podcasts/manifest.json: regenerated, no more ep##-* slugs - html/docs/*.html: 'Full transcript source (external)' links now point at canonical files Code patches: - podcasts/build-bundles.js: emits canonical filenames + slug from EPISODE_MAP - podcasts/generate-draft-transcripts.js: canonical companionBase() helper used in all 3 sites - podcasts/generate-site.js + lib/listening-plan.js: canonical companion lookups - scripts/build-html.js: external companion-script link template uses canonical name - canonicalize-source.ps1: idempotent migration script (dry-run by default) for repeat use
1 parent 49b37e0 commit 9504dc5

237 files changed

Lines changed: 1074 additions & 866 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎canonicalize-source.ps1‎

Lines changed: 149 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,149 @@
1+
<#
2+
.SYNOPSIS
3+
Rename source repo's legacy ep##-<slug> files to canonical names from
4+
docs/EPISODE_MAP.json. Idempotent. Use -DryRun to preview.
5+
6+
.DESCRIPTION
7+
Mirrors c:\code\ggg\canonicalize-site.ps1 on the deploy side. Renames:
8+
- podcasts/scripts/chapters/ep##-*.txt
9+
- podcasts/scripts/appendices/ep##-*.txt
10+
- podcasts/transcripts/chapters/ep##-*-chapters.json
11+
- podcasts/transcripts/chapters/ep##-*-segments.json
12+
- podcasts/transcripts/appendices/ep##-*-chapters.json
13+
- podcasts/transcripts/appendices/ep##-*-segments.json
14+
15+
Skips podcasts/bundles/ -- already canonical.
16+
Does NOT regenerate HTML; run scripts/build-html.js after to refresh
17+
html/docs/*.html companion sections.
18+
19+
.PARAMETER DryRun
20+
Print planned operations without renaming.
21+
#>
22+
[CmdletBinding()]
23+
param(
24+
[switch]$DryRun
25+
)
26+
27+
Set-StrictMode -Version Latest
28+
$ErrorActionPreference = 'Stop'
29+
30+
$Root = $PSScriptRoot
31+
$EpisodeMapPath = Join-Path $Root 'docs\EPISODE_MAP.json'
32+
$ScriptsRoot = Join-Path $Root 'podcasts\scripts'
33+
$TranscriptsRoot = Join-Path $Root 'podcasts\transcripts'
34+
35+
if (-not (Test-Path $EpisodeMapPath)) {
36+
throw "Episode map not found: $EpisodeMapPath"
37+
}
38+
39+
Write-Host "== Loading canonical map from EPISODE_MAP.json =="
40+
$epMap = (Get-Content $EpisodeMapPath -Raw | ConvertFrom-Json)
41+
$narrationToCanonical = @{}
42+
foreach ($ep in $epMap.episodes) {
43+
if ($ep.group -ne 'ep') { continue }
44+
$canonical = $ep.filename -replace '\.mp3$', ''
45+
$narrationToCanonical[$ep.narration_id] = $canonical
46+
}
47+
Write-Host ("Loaded {0} narration_id -> canonical mappings" -f $narrationToCanonical.Count)
48+
49+
function Get-CanonicalBase {
50+
param([string]$LegacyBaseName)
51+
# Parse leading 'ep##' from a name like 'ep00-welcome' or 'ep00-welcome-chapters'
52+
if ($LegacyBaseName -match '^(ep\d{2,})-') {
53+
$narration = $matches[1]
54+
if ($narrationToCanonical.ContainsKey($narration)) {
55+
return $narrationToCanonical[$narration]
56+
}
57+
}
58+
return $null
59+
}
60+
61+
function Invoke-CanonicalRename {
62+
param(
63+
[string]$Dir,
64+
[string]$Filter,
65+
[string[]]$KeepSuffixes
66+
)
67+
if (-not (Test-Path $Dir)) {
68+
Write-Host " (skip, not present) $Dir"
69+
return @{ planned = 0; done = 0; skipped = 0 }
70+
}
71+
$stats = @{ planned = 0; done = 0; skipped = 0; unmapped = @() }
72+
Get-ChildItem $Dir -Filter $Filter | ForEach-Object {
73+
$base = $_.BaseName
74+
$ext = $_.Extension
75+
# Detect suffix like '-chapters' / '-segments'
76+
$suffix = ''
77+
$core = $base
78+
foreach ($s in $KeepSuffixes) {
79+
if ($base.EndsWith($s)) {
80+
$suffix = $s
81+
$core = $base.Substring(0, $base.Length - $s.Length)
82+
break
83+
}
84+
}
85+
$canonical = Get-CanonicalBase $core
86+
if (-not $canonical) {
87+
# Not a legacy ep##-* file (might already be canonical)
88+
if ($core -match '^(ch|ref|tools|git|a11y|agents|sec|cc)-\d+-') {
89+
$stats.skipped++
90+
} else {
91+
$stats.unmapped += $_.Name
92+
}
93+
return
94+
}
95+
$newName = "$canonical$suffix$ext"
96+
$newPath = Join-Path $Dir $newName
97+
if ($newName -eq $_.Name) {
98+
$stats.skipped++
99+
return
100+
}
101+
$stats.planned++
102+
if (Test-Path $newPath) {
103+
Write-Host (" CONFLICT: {0} -> {1} (target already exists)" -f $_.Name, $newName) -ForegroundColor Yellow
104+
return
105+
}
106+
if ($DryRun) {
107+
Write-Host (" DRY: {0} -> {1}" -f $_.Name, $newName)
108+
} else {
109+
Rename-Item -LiteralPath $_.FullName -NewName $newName
110+
Write-Host (" RENAME: {0} -> {1}" -f $_.Name, $newName)
111+
$stats.done++
112+
}
113+
}
114+
if ($stats.unmapped.Count -gt 0) {
115+
Write-Host (" UNMAPPED ({0}):" -f $stats.unmapped.Count) -ForegroundColor Yellow
116+
$stats.unmapped | ForEach-Object { Write-Host " $_" }
117+
}
118+
return $stats
119+
}
120+
121+
Write-Host ""
122+
Write-Host "== podcasts/scripts/chapters =="
123+
$s1 = Invoke-CanonicalRename -Dir (Join-Path $ScriptsRoot 'chapters') -Filter '*.txt' -KeepSuffixes @()
124+
Write-Host (" planned={0} done={1} skipped={2}" -f $s1.planned, $s1.done, $s1.skipped)
125+
126+
Write-Host ""
127+
Write-Host "== podcasts/scripts/appendices =="
128+
$s2 = Invoke-CanonicalRename -Dir (Join-Path $ScriptsRoot 'appendices') -Filter '*.txt' -KeepSuffixes @()
129+
Write-Host (" planned={0} done={1} skipped={2}" -f $s2.planned, $s2.done, $s2.skipped)
130+
131+
Write-Host ""
132+
Write-Host "== podcasts/transcripts/chapters =="
133+
$s3 = Invoke-CanonicalRename -Dir (Join-Path $TranscriptsRoot 'chapters') -Filter '*.json' -KeepSuffixes @('-chapters','-segments')
134+
Write-Host (" planned={0} done={1} skipped={2}" -f $s3.planned, $s3.done, $s3.skipped)
135+
136+
Write-Host ""
137+
Write-Host "== podcasts/transcripts/appendices =="
138+
$s4 = Invoke-CanonicalRename -Dir (Join-Path $TranscriptsRoot 'appendices') -Filter '*.json' -KeepSuffixes @('-chapters','-segments')
139+
Write-Host (" planned={0} done={1} skipped={2}" -f $s4.planned, $s4.done, $s4.skipped)
140+
141+
Write-Host ""
142+
$totalPlanned = $s1.planned + $s2.planned + $s3.planned + $s4.planned
143+
$totalDone = $s1.done + $s2.done + $s3.done + $s4.done
144+
Write-Host ("== SUMMARY == planned={0} done={1}" -f $totalPlanned, $totalDone)
145+
146+
if ($DryRun) {
147+
Write-Host ""
148+
Write-Host "Dry run only. Re-run without -DryRun to apply." -ForegroundColor Cyan
149+
}

‎html/docs/00-pre-workshop-setup.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Pre-Workshop Setup</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-01-pre-workshop-setup.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep01-pre-workshop-setup.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-01-pre-workshop-setup.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. This episode is all about getting ready before Day 1, so the workshop can start with learning instead of setup problems. Please try to finish this at least one day before the event, and if you want the bigger map first, the Get Going with GitHub guide explains GitHub Classroom, your Learning Room repository, Challenge 1, evidence prompts, and tool choices.</p><p><strong>Jamie:</strong> I like that this is pre-work, but not busy work. It&#39;s the stuff that keeps you from getting stuck when everyone else is opening issues, making commits, and trying their first pull request.</p><p><strong>Alex:</strong> Exactly. You&#39;ll want a Windows or macOS computer, a reliable internet connection, and headphones if you&#39;re using screen reader audio during group sessions. Linux users can still follow the Git installation path, but the workshop hardware guidance focuses on Windows and macOS.</p><p><strong>Jamie:</strong> And the software side is a modern browser, a screen reader, and a GitHub account, right? Chrome or Firefox are recommended for GitHub, Edge is fine on Windows, and Safari is usually the best match for VoiceOver on macOS.</p></details>
226226
</article>

‎html/docs/01-choose-your-tools.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Choose Your Tools</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/agents-04-choose-your-tools.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep44-choose-your-tools.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/agents-04-choose-your-tools.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re doing something that can save a lot of frustration later: choosing the tool that fits the job, instead of assuming there is one correct way to use GitHub.</p><p><strong>Jamie:</strong> I like that framing, because people can feel behind before they even start. One person is in a browser, someone else is in VS Code, someone else is using a terminal, and it can sound like they are all in different workshops.</p><p><strong>Alex:</strong> They are using different doors into the same work. The workshop supports multiple tool paths because real teams do that too. A chapter might say, &quot;open the file,&quot; and your job is to know whether that means the GitHub website, github.dev, VS Code, GitHub Desktop, or the GitHub CLI for you.</p><p><strong>Jamie:</strong> So we are not choosing a tool forever. We are learning what each one is good at, what it cannot do, and how it feels with a screen reader or low vision setup.</p></details>
226226
</article>

‎html/docs/02-understanding-github.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Understanding GitHub on the Web</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-02-github-web-structure.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep02-github-web-structure.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-02-github-web-structure.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re building the map you use before you click anything on GitHub. GitHub can feel like one giant website, but it makes more sense when you know what level you&#39;re on and what landmarks are always nearby.</p><p><strong>Jamie:</strong> I like starting there, because the confusing moment is usually not, &quot;What button do I press?&quot; It&#39;s, &quot;Where am I, and what kind of page is this?&quot;</p><p><strong>Alex:</strong> Exactly. GitHub has three nested levels. Level one is your own account area, like your profile, settings, and notifications. Level two is a user or organization space, such as github.com/github or github.com/community-access. Level three is a repository, and that is where issues, pull requests, code, actions, branches, and files live.</p><p><strong>Jamie:</strong> So when a workshop says, &quot;go to the repo,&quot; it usually means that third level. And for Challenge 01, Find Your Way Around, learners will practice that inside their own Learning Room repository, which is provisioned for each learner.</p></details>
226226
</article>

‎html/docs/03-navigating-repositories.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Navigating Repositories</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-03-navigating-repositories.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep03-navigating-repositories.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-03-navigating-repositories.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re getting comfortable inside a GitHub repository, which is the place most of your collaboration work starts.</p><p><strong>Jamie:</strong> And repository is one of those words people hear constantly, but it can still feel fuzzy. What is it, in plain language?</p><p><strong>Alex:</strong> A repository is a project folder tracked by Git. It can hold code, documents, images, configuration files, and the history of changes to all of those files. On GitHub, the repository page is the web view of that project.</p><p><strong>Jamie:</strong> So when I open a repo, I&#39;m not just looking at a file cabinet. I&#39;m looking at the current project plus its memory.</p></details>
226226
</article>

‎html/docs/04-the-learning-room.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>The Learning Room</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-04-the-learning-room.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep04-the-learning-room.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-04-the-learning-room.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re getting oriented in the Learning Room, which is your private practice repository for Day 1 of the workshop.</p><p><strong>Jamie:</strong> I like starting there, because a new GitHub repository can feel like walking into a room with a lot of unlabeled doors.</p><p><strong>Alex:</strong> Exactly. The Learning Room is a GitHub repo created for you through GitHub Classroom. It starts from the Community-Access/learning-room-template repository, but your copy lives in the workshop organization with a name like &lt;workshop-org&gt;/learning-room-&lt;your-username&gt;.</p><p><strong>Jamie:</strong> So I am not editing the template repository itself.</p></details>
226226
</article>

‎html/docs/05-working-with-issues.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Working with Issues</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-05-working-with-issues.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep05-working-with-issues.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-05-working-with-issues.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re working with GitHub issues, which are often where collaboration starts.</p><p><strong>Jamie:</strong> And an issue can be a bug report, but it&#39;s not only bugs, right?</p><p><strong>Alex:</strong> Right. An issue is a trackable unit of work. It might be a bug, a feature request, a question, a documentation chore, or a note that says, something needs attention here.</p><p><strong>Jamie:</strong> So it is the shared place where people agree on what needs to happen before anyone starts changing files.</p></details>
226226
</article>

‎html/docs/06-working-with-pull-requests.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Working with Pull Requests</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-06-working-with-pull-requests.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep06-working-with-pull-requests.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-06-working-with-pull-requests.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re working with pull requests, which is where a change stops being just your local work and becomes a proposal for a project to accept.</p><p><strong>Jamie:</strong> So a pull request is not the change itself, exactly. It&#39;s the conversation around whether that change should be merged?</p><p><strong>Alex:</strong> Right. A pull request, or PR, proposes merging changes from one branch into another branch. An issue is usually the problem, request, or task. The PR is the proposed fix, with the files, commits, discussion, checks, and review all gathered in one place.</p><p><strong>Jamie:</strong> That helps. An issue can say, &quot;This link is broken,&quot; and the PR says, &quot;Here is the branch where I fixed that link. Please review it.&quot;</p></details>
226226
</article>

‎html/docs/07-merge-conflicts.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ <h3>Merge Conflicts Are Not Scary</h3>
220220
<p class="companion-links">
221221
<a href="https://lp.csedesigns.com/ggg/media/ch-07-merge-conflicts.mp3" target="_blank" rel="noopener noreferrer">Open audio file (external)</a>
222222
<span aria-hidden="true"> · </span>
223-
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ep07-merge-conflicts.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
223+
<a href="https://github.com/Community-Access/git-going-with-github/blob/main/podcasts/scripts/chapters/ch-07-merge-conflicts.txt" target="_blank" rel="noopener noreferrer">Full transcript source (external)</a>
224224
</p>
225225
<details class="companion-preview"><summary>Transcript preview</summary><p><strong>Alex:</strong> Welcome back. Today we&#39;re taking the fear out of merge conflicts. A conflict can look dramatic on the screen, but most of the time it is Git saying, &quot;I found two edits in the same place, and I need a human to choose.&quot;</p><p><strong>Jamie:</strong> That already makes it sound less like an emergency. I think the scary part is seeing those rows of angle brackets and wondering if you broke the project.</p><p><strong>Alex:</strong> You did not break the project. Conflicts are a normal part of collaboration, including collaboration with AI tools that may rewrite something a human already changed. The skill is reading the choices calmly, keeping the right content, and leaving the file clean.</p><p><strong>Jamie:</strong> So this is not a punishment from Git. It&#39;s a checkpoint where the person with context makes the final call.</p></details>
226226
</article>

0 commit comments

Comments
 (0)