feat: open Markdown files and in-app updater
Markdown: - File > Open Markdown File... and welcome-screen 'Open .md' import one or more .md files as new books (named after first H1 or the filename; originals never modified, collision-safe folder names). - Book dirs and .md files passed on the command line or via desktop file associations now open directly; single-instance lock forwards second launches to the running window. Updates: - File > Check for Updates... and welcome-screen 'Update' button: queries the Gitea releases API, one-click installs a newer release into ~/.local/share/Folio via a detached swap script that waits for app exit, keeps the old tree until the swap succeeds, and relaunches. Download is gzip-verified and restricted to the trusted release host. No root, no reinstall. Tests: 19 new assertions in tests/run-update-import-test.mjs (wired into npm test); full suite green, tsc clean.
This commit is contained in:
parent
9aebde4c35
commit
ada5eee679
12 changed files with 634 additions and 5 deletions
|
|
@ -15,7 +15,7 @@
|
|||
"dev": "concurrently -k \"npm run build:watch\" \"wait-on dist/main.js && npm run electron\"",
|
||||
"start": "npm run build && npm run electron",
|
||||
"lint": "tsc --noEmit",
|
||||
"test": "node tests/run-project-test.mjs && node tests/run-chapters-test.mjs && node tests/run-wikilinks-test.mjs && node tests/run-office-export-test.mjs && node tests/run-migration-test.mjs && node tests/run-editor-test.mjs && node tests/run-fullbook-test.mjs && node tests/run-print-test.mjs",
|
||||
"test": "node tests/run-project-test.mjs && node tests/run-chapters-test.mjs && node tests/run-wikilinks-test.mjs && node tests/run-office-export-test.mjs && node tests/run-migration-test.mjs && node tests/run-editor-test.mjs && node tests/run-fullbook-test.mjs && node tests/run-print-test.mjs && node tests/run-update-import-test.mjs",
|
||||
"package": "electron-builder"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue