2 Commits
Author SHA1 Message Date
Jarvis 62738c35b2 chore: release 1.4.1
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-09 22:21:19 +01:00
Jarvis cf4de4ce36 fix: normalize Windows paths to forward slashes for Typst
Fixes Windows "syntax error" (OS error 123) when template paths
contain backslashes. Typst interprets backslashes as escape
characters, causing invalid filename syntax errors.

Now converts all template paths to use forward slashes before
passing to Typst via variables. Typst accepts forward slashes
on all platforms including Windows.

Fixes: #10

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-09 22:20:23 +01:00
5 changed files with 13 additions and 3 deletions

No files matched your search

+5
View File
@@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased] ## [Unreleased]
## [1.4.1] - 2025-01-09
### Fixed
- Windows path handling in Typst template variables - backslashes now normalized to forward slashes to prevent Typst syntax errors (OS error 123: "The syntax for the filename, directory name or volume label is incorrect")
## [1.4.0] - 2025-01-09 ## [1.4.0] - 2025-01-09
### Added ### Added
+1 -1
View File
@@ -1,7 +1,7 @@
{ {
"id": "typst-pdf-export", "id": "typst-pdf-export",
"name": "Typst PDF Export", "name": "Typst PDF Export",
"version": "1.4.0", "version": "1.4.1",
"minAppVersion": "1.9.12", "minAppVersion": "1.9.12",
"description": "Exports a note or collection of notes to a pretty Typst PDF.", "description": "Exports a note or collection of notes to a pretty Typst PDF.",
"author": "Alexander Kucera", "author": "Alexander Kucera",
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "obsidian-typst-pdf-export", "name": "obsidian-typst-pdf-export",
"version": "1.4.0", "version": "1.4.1",
"description": "Exports a note or collection of notes to a pretty Typst PDF.", "description": "Exports a note or collection of notes to a pretty Typst PDF.",
"main": "main.js", "main": "main.js",
"scripts": { "scripts": {
@@ -311,6 +311,10 @@ export class PandocCommandBuilder {
templatePathForTypst = path.relative(pandocOptions.vaultBasePath, templatePathForTypst); templatePathForTypst = path.relative(pandocOptions.vaultBasePath, templatePathForTypst);
} }
// Normalize to forward slashes for Typst (Typst uses forward slashes on all platforms)
// This prevents Windows backslashes from being interpreted as escape characters in Typst
templatePathForTypst = templatePathForTypst.replace(/\\/g, '/');
args.push('-V', `template_path=${templatePathForTypst}`); args.push('-V', `template_path=${templatePathForTypst}`);
} }
} }
+2 -1
View File
@@ -6,5 +6,6 @@
"1.2.1": "1.9.12", "1.2.1": "1.9.12",
"1.3.0": "1.9.12", "1.3.0": "1.9.12",
"1.3.1": "1.9.12", "1.3.1": "1.9.12",
"1.4.0": "1.9.12" "1.4.0": "1.9.12",
"1.4.1": "1.9.12"
} }