joplin icon indicating copy to clipboard operation
joplin copied to clipboard

Desktop: Add support for OneNote importer

Open pedr opened this issue 3 months ago • 1 comments

This is still a draft PR.

I'm adding a new package library that will be used to convert OneNote exports into Joplin Notes.

The onenote-converter is based on the implementations found in: https://github.com/msiemens/one2html https://github.com/msiemens/onenote.rs

We will be compiling the Rust code to wasm with the package wasm-pack to output a Node package that can be imported in our codebase.

Command to create node package

yarn dlx wasm-pack build ./packages/onenote-converter --target nodejs --scope joplin --debug yarn dlx wasm-pack build ./packages/onenote-converter --target nodejs --scope joplin --release


Todos:

  • [x] Try to find a better way for the first install of project
    • ~Right now the easiest solution to this is to ask for the user to run the CLI command to build the package before running yarn install~
    • We just use a package.json to point to the real files that don't exist yet
    • [ ] fix error in CI
  • [ ] Disable import in app-cli

pedr avatar Apr 03 '24 13:04 pedr

Some failures on CI:

2024-04-03T13:45:29.7543910Z ➤ YN0000: ┌ Resolution step
2024-04-03T13:45:29.7545630Z ##[group]Resolution step
2024-04-03T13:45:30.7137160Z ➤ YN0001: │ Error: onenote-converter@file:../onenote-converter/pkg::locator=%40joplin%2Flib%40workspace%3Apackages%2Flib: ENOENT: no such file or directory, lstat '/Users/runner/work/joplin/joplin/packages/onenote-converter/pkg'
2024-04-03T13:45:30.7346050Z ##[endgroup]
2024-04-03T13:45:30.7351150Z ➤ YN0001: Error: onenote-converter@file:../onenote-converter/pkg::locator=%40joplin%2Flib%40workspace%3Apackages%2Flib: ENOENT: no such file or directory, lstat '/Users/runner/work/joplin/joplin/packages/onenote-converter/pkg'
2024-04-03T13:45:30.7355690Z ➤ YN0000: └ Completed in 0s 957ms
2024-04-03T13:45:30.7357660Z ➤ YN0000: Failed with errors in 0s 966ms
2024-04-03T13:45:30.7632990Z Yarn installation failed. Search for 'exit code 1' in the log for more information.
2024-04-03T13:45:30.7652800Z ##[error]Process completed with exit code 1.
2024-04-03T13:45:30.7811060Z Post job cleanup.

laurent22 avatar Apr 03 '24 18:04 laurent22