Skip to content

Commit 6018541

Browse files
authored
Fix walkthrough assets not available in build (#127)
1 parent 9c15bdd commit 6018541

10 files changed

+9
-9
lines changed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

package.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@
181181
"title": "Check Manim Installation",
182182
"description": "Let's see if you have installed ManimGL.\n[Check Manim version](command:manim-notebook.redetectManimVersion)\n[Open installation guide](https://3b1b.github.io/manim/getting_started/installation.html)",
183183
"media": {
184-
"markdown": "src/walkthrough/manim-installation.md"
184+
"markdown": "assets/walkthrough/manim-installation.md"
185185
},
186186
"completionEvents": [
187187
"onCommand:manim-notebook.redetectManimVersion"
@@ -192,7 +192,7 @@
192192
"title": "Start with an example",
193193
"description": "Open an example file to see how Manim Notebook works.\n[Open Sample](command:manim-notebook-walkthrough.openSample)",
194194
"media": {
195-
"svg": "src/walkthrough/preview-cell.svg",
195+
"svg": "assets/walkthrough/preview-cell.svg",
196196
"altText": "Preview Manim Cell"
197197
},
198198
"completionEvents": [
@@ -204,7 +204,7 @@
204204
"title": "Show all available commands",
205205
"description": "Get a list of all available commands in Manim Notebook.\n[Show Commands](command:manim-notebook-walkthrough.showCommands)",
206206
"media": {
207-
"svg": "src/walkthrough/commands.svg",
207+
"svg": "assets/walkthrough/commands.svg",
208208
"altText": "Manim Notebook commands"
209209
},
210210
"completionEvents": [
@@ -216,7 +216,7 @@
216216
"title": "Show keyboard shortcuts",
217217
"description": "See all available keyboard shortcuts in Manim Notebook and modify them to whatever you like.\n[Show Shortcuts](command:manim-notebook-walkthrough.showShortcuts)",
218218
"media": {
219-
"svg": "src/walkthrough/shortcuts.svg",
219+
"svg": "assets/walkthrough/shortcuts.svg",
220220
"altText": "Manim Notebook keyboard shortcuts"
221221
},
222222
"completionEvents": [
@@ -228,7 +228,7 @@
228228
"title": "Show settings",
229229
"description": "Customize your Manim Notebook experience by changing settings.\n[Show Settings](command:manim-notebook-walkthrough.showSettings)",
230230
"media": {
231-
"svg": "src/walkthrough/settings.svg",
231+
"svg": "assets/walkthrough/settings.svg",
232232
"altText": "Manim Notebook settings"
233233
},
234234
"completionEvents": [
@@ -240,7 +240,7 @@
240240
"title": "Open Wiki",
241241
"description": "Learn more about Manim Notebook on the GitHub Wiki.\n[Open Wiki](command:manim-notebook-walkthrough.openWiki)",
242242
"media": {
243-
"svg": "src/walkthrough/wiki.svg",
243+
"svg": "assets/walkthrough/wiki.svg",
244244
"altText": "Manim Notebook Wiki"
245245
},
246246
"completionEvents": [

src/extension.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { previewManimCell, reloadAndPreviewManimCell, previewCode } from "./prev
66
import { startScene, exitScene } from "./startStopScene";
77
import { exportScene } from "./export";
88
import { Logger, Window, LogRecorder } from "./logger";
9-
import { registerWalkthroughCommands } from "./walkthrough/commands";
9+
import { registerWalkthroughCommands } from "./walkthrough";
1010
import { ExportSceneCodeLens } from "./export";
1111
import { determineManimVersion } from "./manimVersion";
1212
import { setupTestEnvironment } from "./utils/testing";

src/walkthrough/commands.ts renamed to src/walkthrough.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import * as vscode from "vscode";
22
import { ExtensionContext, window, workspace, commands } from "vscode";
3-
import { Logger } from "../logger";
3+
import { Logger } from "./logger";
44
import fs from "fs";
55
import path from "path";
66

@@ -55,7 +55,7 @@ export function registerWalkthroughCommands(context: ExtensionContext) {
5555
*/
5656
async function openSampleFile(context: ExtensionContext) {
5757
const sampleFilePath = path.join(context.extensionPath,
58-
"src", "walkthrough", "sample_scene.py");
58+
"assets", "walkthrough", "sample_scene.py");
5959
const sampleFileContent = fs.readFileSync(sampleFilePath, "utf-8");
6060

6161
const sampleFile = await workspace.openTextDocument({

0 commit comments

Comments
 (0)