Skip to content

Improvements to Markdown Extraction and Formatting#56

Open
BillTribble wants to merge 7 commits intoHamburgChimps:mainfrom
BillTribble:fix/checklist-and-formatting-improvements
Open

Improvements to Markdown Extraction and Formatting#56
BillTribble wants to merge 7 commits intoHamburgChimps:mainfrom
BillTribble:fix/checklist-and-formatting-improvements

Conversation

@BillTribble
Copy link
Copy Markdown

@BillTribble BillTribble commented Apr 2, 2026

Pull Request: Improvements to Markdown Extraction and Formatting

This PR fixes the extraction process which was failing on my db, and introduces several enhancements, focusing on Markdown compatibility, and notes organization.

Key Changes

1. Markdown Formatting & Compatibility

  • Checklist Rendering: Fixed logic for checklist items to ensure they render correctly in Notesnook. (Used 'Obsidian' format as input)
  • Sanitization: Standardized text by replacing non-standard characters (like non-breaking spaces \u00A0) with regular spaces.
  • Line Break Logic: Optimized paragraph handling to avoid excessive blank lines while maintaining list integrity.
  • Formatted Runs: Fixed excessive bolding/formatting by merging adjacent runs with identical styles.

2. Export Organization

  • Year-based Folders: Exported notes are now organized into subfolders by year (e.g., 2025/, 2026/), making large libraries easier to navigate.
  • Filename Improvements: Improved filename generation to better handle note titles while maintaining filesystem safety.

3. Metadata & Stability

  • Timestamps: Restored Created At and Updated At timestamps at the end of each Markdown file.
  • Duplicate Titles: Removed redundant note titles that were being duplicated in some extraction scenarios.
  • NPE Fixes: Added null checks to prevent NullPointerException during the extraction of complex notes.

Verification

  • Verified against a large library of Apple Notes.
  • All unit tests pass using ./mvnw clean test.
  • Visual verification performed in Notesnook.

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