Skip to content

new-note-namer: fix rename prompt firing on existing notes (#300) - #302

Merged
pbek merged 1 commit into
qownnotes:mainfrom
luginf:new-note-namer2
Sep 28, 2026
Merged

pbek merged 1 commit into
qownnotes:mainfrom
luginf:new-note-namer2

Conversation

@luginf

@luginf luginf commented Sep 28, 2026

Copy link
Copy Markdown
Contributor

@pbek sorry for the fuss, the precedent version (#301) was wrong. This one should be better!

Fixes #300

note.fileCreated == "Invalid Date" was used to detect a brand-new note, but it also reads "Invalid Date" the first time a pre-existing, not-yet-indexed note file is edited and saved -- it marks "new DB row", not "new file on disk". This made the script wrongly prompt for a file name on existing notes.

Replace it with a one-shot flag set in handleNewNoteHeadlineHook, which only fires for genuine new-note creation, immediately before handleNoteTextFileNameHook.

Bump to 0.0.5 and add a CHANGELOG entry.

…#300)

note.fileCreated == "Invalid Date" was used to detect a brand-new
note, but it also reads "Invalid Date" the first time a pre-existing,
not-yet-indexed note file is edited and saved -- it marks "new DB
row", not "new file on disk". This made the script wrongly prompt for
a file name on existing notes.

Replace it with a one-shot flag set in handleNewNoteHeadlineHook,
which only fires for genuine new-note creation, immediately before
handleNoteTextFileNameHook.

Bump to 0.0.5 and add a CHANGELOG entry.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@pbek
pbek merged commit 9864932 into qownnotes:main Sep 28, 2026
2 checks passed
@pbek

pbek commented Sep 28, 2026

Copy link
Copy Markdown
Member

Thank you!

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.

[BUG] New note namer runs on existing notes

2 participants