Markdown Workspace is a desktop Markdown editor built with Electron, Vue, Pinia, Markdown-it, Highlight.js and Mermaid.
npm ci
npm startIf Electron was installed without its binary, run:
node node_modules\electron\install.jsnpx tsc --noEmit
npm run lint
npm run build:appnpm run packCreates an unpacked app in release/win-unpacked/.
npm run distCreates the Windows NSIS installer, blockmap and update metadata in release/ without publishing.
Publish only these files manually:
Markdown-Workspace-<version>-x64.exeMarkdown-Workspace-<version>-x64.exe.blockmaplatest.yml
Do not upload these local/debug outputs manually:
win-unpacked/builder-effective-config.yamlbuilder-debug.yml
There are two valid publishing flows. Use one of them, not both.
Push a version tag:
git tag v1.0.3
git push origin v1.0.3The tag starts .github/workflows/release.yml. The workflow runs npm run release on GitHub's Windows runner and publishes the required assets to GitHub Releases.
Do not run npm run dist before this flow. GitHub Actions builds from a clean checkout.
Run this only if you want to publish from your machine:
$env:GH_TOKEN="your_github_token"
npm run releasenpm run release builds the app and uploads the required assets directly to GitHub Releases. In this flow you do not need to push a tag first; electron-builder can create or update the GitHub release using the version from package.json.
For this project, GitHub Actions is preferred because local Windows builds can fail while extracting winCodeSign if symbolic links are not allowed.
GITHUB_TOKEN is provided automatically by GitHub Actions. Do not create it manually.
Optional Windows code-signing secrets:
WIN_CSC_LINK: URL or base64 content of a.pfxsigning certificate.WIN_CSC_KEY_PASSWORD: password for that.pfxcertificate.
If you do not have a signing certificate, leave both secrets empty. The build can still publish an unsigned installer, but Windows SmartScreen may warn users.
Auto-updates work only from an installed packaged app. The updater uses:
electron-updaterin the Electron main process.- GitHub Releases as the provider.
latest.ymland*.blockmapgenerated byelectron-builder.
Draft releases are ignored by the updater. The release must be published.
The npm package is present, but the Electron executable was not downloaded. Fix:
node node_modules\electron\install.js
npm startThis is a local Windows permission problem in electron-builder, not an app build error. electron-builder downloads winCodeSign-*.7z, and 7-Zip tries to create symbolic links in:
%LOCALAPPDATA%\electron-builder\Cache\winCodeSign
Fix options:
- Enable Windows Developer Mode: Settings -> System -> For developers -> Developer Mode.
- Or run the terminal as Administrator.
- Delete the broken cache and retry:
Remove-Item -Recurse -Force "$env:LOCALAPPDATA\electron-builder\Cache\winCodeSign"
npm run distMarkdown Workspace - настольный Markdown-редактор на Electron и Vue.
npm ci
npm startnpx tsc --noEmit
npm run lint
npm run build:appnpm run distКоманда только собирает файлы в release/, но не публикует их.
Для ручной загрузки в GitHub Releases нужны только:
.exe.exe.blockmaplatest.yml
win-unpacked/, builder-effective-config.yaml и builder-debug.yml - служебные файлы, их загружать не нужно.
Есть два варианта. Используйте один, не оба сразу.
Вариант 1 - GitHub Actions:
git tag v1.0.3
git push origin v1.0.3Tag запускает workflow. Workflow сам выполнит npm run release на GitHub runner. Перед этим не нужно запускать npm run dist.
Вариант 2 - локальная публикация:
$env:GH_TOKEN="your_github_token"
npm run releaseВ этом варианте npm run release сам собирает и публикует релиз через токен.