Skip to content

Commit 69b8b30

Browse files
DanWahlinCopilot
andcommitted
docs(migration): add Learn frontmatter and asset paths
Add commented GitHub Learn frontmatter to the course README files and include the course-level metadata files. Rename image asset folders to assets and update Markdown, instructions, and helper scripts to match the new paths. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 6466e18 commit 69b8b30

114 files changed

Lines changed: 258 additions & 110 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.

.github/copilot-instructions.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,15 +47,15 @@ Do not deviate from this structure when editing or adding chapter content.
4747
## Markdown Formatting
4848

4949
- Use standard GitHub-Flavored Markdown.
50-
- Images go in the repo-root `images/` directory.
50+
- Images go in the repo-root `assets/` directory.
5151
- Use relative links for cross-chapter references (e.g., `../03-development-workflows/README.md`).
5252
- Emoji usage is encouraged for section headers (matching existing style).
5353

5454
## Maintenance Matrix
5555

5656
| Change Made | Files to Update |
5757
|---|---|
58-
| New chapter added | `README.md` (course table), `AGENTS.md` (structure table), `images/learning-path.png` |
58+
| New chapter added | `README.md` (course table), `AGENTS.md` (structure table), `assets/learning-path.png` |
5959
| Chapter content updated | The chapter's `README.md`, verify cross-references in adjacent chapters |
6060
| New sample app variant added | `AGENTS.md` (structure table), `samples/` directory, relevant chapter references |
6161
| Sample app code changed | `samples/book-app-project/tests/` (update/add tests), chapters referencing that code |
@@ -66,5 +66,5 @@ Do not deviate from this structure when editing or adding chapter content.
6666
| Glossary term introduced | `GLOSSARY.md` — add definition in alphabetical order |
6767
| npm scripts changed | `package.json`, `AGENTS.md` (build section) |
6868
| Devcontainer updated | `.devcontainer/devcontainer.json`, Chapter 00 (setup instructions) |
69-
| Image or banner changed | `images/` directory, any README referencing the image |
69+
| Image or banner changed | `assets/` directory, any README referencing the image |
7070
| Copilot CLI version requirements change | Chapter 00, Chapter 01, `.devcontainer/devcontainer.json` |

.github/scripts/create-tapes.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -136,21 +136,21 @@ console.log('📝 Creating tape files from demos.json...\n');
136136
let created = 0;
137137

138138
for (const demo of config.demos) {
139-
const imagesDir = join(rootDir, demo.chapter, 'images');
140-
const tapePath = join(imagesDir, `${demo.name}.tape`);
139+
const assetsDir = join(rootDir, demo.chapter, 'assets');
140+
const tapePath = join(assetsDir, `${demo.name}.tape`);
141141

142-
// Ensure images directory exists
143-
if (!existsSync(imagesDir)) {
144-
mkdirSync(imagesDir, { recursive: true });
145-
console.log(` Created: ${demo.chapter}/images/`);
142+
// Ensure assets directory exists
143+
if (!existsSync(assetsDir)) {
144+
mkdirSync(assetsDir, { recursive: true });
145+
console.log(` Created: ${demo.chapter}/assets/`);
146146
}
147147

148148
// Generate tape content
149149
const content = generateTapeContent(demo, config.settings);
150150

151151
// Write tape file
152152
writeFileSync(tapePath, content);
153-
console.log(` ✓ ${demo.chapter}/images/${demo.name}.tape`);
153+
console.log(` ✓ ${demo.chapter}/assets/${demo.name}.tape`);
154154
created++;
155155
}
156156

.github/scripts/generate-chapter-headers.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
# Get project root (parent of scripts folder)
2424
SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__))
2525
PROJECT_ROOT = os.path.dirname(os.path.dirname(SCRIPT_DIR))
26-
BACKGROUND_IMAGE = os.path.join(PROJECT_ROOT, "images", "chapter-header-bg.png")
26+
BACKGROUND_IMAGE = os.path.join(PROJECT_ROOT, "assets", "chapter-header-bg.png")
2727

2828
# Font settings - 25% larger than original 36px
2929
FONT_SIZE = 45
@@ -112,8 +112,8 @@ def generate_header(chapter_folder, title, font):
112112
y = (height - text_height) // 2
113113
draw.text((x, y), title, fill=(255, 255, 255), font=font)
114114

115-
# Save to chapter's images folder
116-
output_dir = os.path.join(PROJECT_ROOT, chapter_folder, "images")
115+
# Save to chapter's assets folder
116+
output_dir = os.path.join(PROJECT_ROOT, chapter_folder, "assets")
117117
os.makedirs(output_dir, exist_ok=True)
118118

119119
output_path = os.path.join(output_dir, "chapter-header.png")

.github/scripts/generate-demos.js

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/**
33
* Generate course demo GIFs from .tape files
44
*
5-
* This script finds all .tape files in [chapter]/images/ folders and runs VHS
5+
* This script finds all .tape files in [chapter]/assets/ folders and runs VHS
66
* to generate GIFs. VHS is run from the project root so that @file references
77
* in prompts resolve correctly.
88
*
@@ -135,7 +135,7 @@ function cleanupCopilotWrapper() {
135135
try { rmSync(wrapperDir, { recursive: true }); } catch (e) { /* ignore */ }
136136
}
137137

138-
// Find all .tape files in [chapter]/images/ folders
138+
// Find all .tape files in [chapter]/assets/ folders
139139
function findTapeFiles(dir, chapterFilter) {
140140
const tapeFiles = [];
141141

@@ -151,17 +151,17 @@ function findTapeFiles(dir, chapterFilter) {
151151
if (!matches) continue;
152152
}
153153

154-
const imagesDir = join(fullPath, 'images');
155-
if (existsSync(imagesDir)) {
154+
const assetsDir = join(fullPath, 'assets');
155+
if (existsSync(assetsDir)) {
156156
try {
157-
const imagesEntries = readdirSync(imagesDir);
158-
for (const file of imagesEntries) {
157+
const assetsEntries = readdirSync(assetsDir);
158+
for (const file of assetsEntries) {
159159
if (file.endsWith('.tape')) {
160-
tapeFiles.push(join(imagesDir, file));
160+
tapeFiles.push(join(assetsDir, file));
161161
}
162162
}
163163
} catch (e) {
164-
// Can't read images folder, skip
164+
// Can't read assets folder, skip
165165
}
166166
}
167167
}

.github/scripts/preview-gifs.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@ function findGifs() {
3232
const gifs = [];
3333
for (const entry of readdirSync(rootDir)) {
3434
if (!/^\d{2}-/.test(entry)) continue;
35-
const imagesDir = join(rootDir, entry, 'images');
36-
if (!existsSync(imagesDir)) continue;
37-
for (const file of readdirSync(imagesDir)) {
35+
const assetsDir = join(rootDir, entry, 'assets');
36+
if (!existsSync(assetsDir)) continue;
37+
for (const file of readdirSync(assetsDir)) {
3838
if (file.endsWith('-demo.gif')) {
39-
gifs.push({ path: join(imagesDir, file), chapter: entry });
39+
gifs.push({ path: join(assetsDir, file), chapter: entry });
4040
}
4141
}
4242
}

.github/scripts/verify-gifs.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,11 @@ function findGifs(dir) {
4141
const fullPath = join(dir, entry);
4242
const stat = statSync(fullPath);
4343
if (stat.isDirectory() && !entry.startsWith('.') && entry !== 'node_modules') {
44-
const imagesDir = join(fullPath, 'images');
45-
if (existsSync(imagesDir)) {
46-
for (const file of readdirSync(imagesDir)) {
44+
const assetsDir = join(fullPath, 'assets');
45+
if (existsSync(assetsDir)) {
46+
for (const file of readdirSync(assetsDir)) {
4747
if (file.endsWith('-demo.gif')) {
48-
gifs.push(join(imagesDir, file));
48+
gifs.push(join(assetsDir, file));
4949
}
5050
}
5151
}

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,4 +101,5 @@ Desktop.ini
101101
.plans
102102
.plans.vhs-wrapper
103103
demo-previews
104-
blog
104+
blog
105+
migration.md

00-quick-start/README.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,15 @@
1-
![Chapter 00: Quick Start](images/chapter-header.png)
1+
<!--
2+
---
3+
id: CopilotCLI-00
4+
title: !translate Quick Start
5+
description: !translate Install GitHub Copilot CLI, sign in with your GitHub account, and verify that everything works.
6+
audience: Developers / Students / Terminal users
7+
slug: quick-start
8+
weight: 1
9+
---
10+
-->
11+
12+
![Chapter 00: Quick Start](assets/chapter-header.png)
213

314
Welcome! In this chapter, you'll get GitHub Copilot CLI (Command Line Interface) installed, signed in with your GitHub account, and verified that everything works. This is a quick setup chapter. Once you're up and running, the real demos start in Chapter 01!
415

@@ -124,7 +135,7 @@ copilot
124135
125136
You'll be asked to trust the folder containing the repository (if you haven't already). You can trust it one time or across all future sessions.
126137
127-
<img src="images/copilot-trust.png" alt="Trusting files in a folder with the Copilot CLI" width="800"/>
138+
<img src="assets/copilot-trust.png" alt="Trusting files in a folder with the Copilot CLI" width="800"/>
128139
129140
After trusting the folder, you can sign in with your GitHub account.
130141
@@ -140,7 +151,7 @@ After trusting the folder, you can sign in with your GitHub account.
140151
4. Select "Authorize" to grant GitHub Copilot CLI access
141152
5. Return to your terminal - you're now signed in!
142153

143-
<img src="images/auth-device-flow.png" alt="Device Authorization Flow - showing the 5-step process from terminal login to signed-in confirmation" width="800"/>
154+
<img src="assets/auth-device-flow.png" alt="Device Authorization Flow - showing the 5-step process from terminal login to signed-in confirmation" width="800"/>
144155

145156
*The device authorization flow: your terminal generates a code, you verify it in the browser, and Copilot CLI is authenticated.*
146157

@@ -169,7 +180,7 @@ After you receive a response, you can exit the CLI:
169180
<details>
170181
<summary>🎬 See it in action!</summary>
171182
172-
![Hello Demo](images/hello-demo.gif)
183+
![Hello Demo](assets/hello-demo.gif)
173184
174185
*Demo output varies. Your model, tools, and responses will differ from what's shown here.*
175186

File renamed without changes.

0 commit comments

Comments
 (0)