Skip to content

Fix G keep notes issues#8

Open
froston wants to merge 1 commit into
mgks:mainfrom
froston:fix-issues-with-keep-notes
Open

Fix G keep notes issues#8
froston wants to merge 1 commit into
mgks:mainfrom
froston:fix-issues-with-keep-notes

Conversation

@froston
Copy link
Copy Markdown

@froston froston commented Apr 21, 2026

Summary

  • Dates: Apple Notes / Evernote imports were showing today's date for every note because the upstream gkeep-parser silently falls back to new Date() when it can't parse the localized .heading text. We now use the source file's last‑modified time (ZIP central‑directory date for archives, File.lastModified for raw drops) as the authoritative created / updated timestamp.
  • Format detection: Files with the ._keep extension were being rejected as an unknown format. They are now recognized as Google Keep alongside .html, so Takeout exports that ship ._keep files import correctly.
  • ENEX output: Emit a proper <updated> element and route every date through a safe toEnexDate() helper instead of inline string‑munging that assumed already‑ISO input.

Changes

  • src/modules/worker.js: scan now reports each ZIP entry's lastModified; extract returns a dateMap keyed by path.
  • src/main.js: thread combinedDateMap from extraction → finishConversion, override each parsed note's created/updated with the file date, add toEnexDate() and emit <updated> in the ENEX output.
  • src/config/formats.js: detectFormat now recognizes ._keep files as Google Keep.

Test plan

  • Import a Google Takeout Keep ZIP whose entries have historical mtimes; export to .enex and confirm Apple Notes shows the original dates instead of today.
  • Drag‑and‑drop loose .html Keep notes; verify File.lastModified is used for the ENEX <created> timestamp.
  • Drop a ._keep file (or a ZIP containing them) and confirm it's detected as Google Keep and converts successfully.
  • Re‑run an existing ENEX → Markdown conversion to confirm no regression for non‑Keep sources.

@froston froston closed this Apr 21, 2026
@froston froston reopened this Apr 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant