Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import of markdown directory only adds linked images #4433

Closed
ghost opened this issue Jan 27, 2021 · 7 comments
Closed

Import of markdown directory only adds linked images #4433

ghost opened this issue Jan 27, 2021 · 7 comments
Labels
backlog We'll get to it... eventually... bug It's a bug desktop All desktop platforms medium Medium priority issues

Comments

@ghost
Copy link

ghost commented Jan 27, 2021

When importing Markdown from a directory I can successfully import linked images such as ![image](/uploads/c9e3d083363999c2486dfdc97d642bc6/image.png). These get transformed into something like ![image](:/ac0125f1effe4bd19ed096d6135fcec8). However, other files such as pdfs or pptx cannot be successfully imported. The link remains as is and the file cannot be opened from within Joplin.

Environment

Joplin version: 1.4.19
Platform: Windows

Steps to reproduce

  1. Create a directory with a markdown file refering to a non-image file within this directory.
  2. Import this directory into Joplin

Describe what you expected to happen

The non-image file does not get imported.

@ghost ghost added the bug It's a bug label Jan 27, 2021
@stale
Copy link

stale bot commented Mar 5, 2021

Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may comment on the issue and I will leave it open. Thank you for your contributions.

@stale stale bot added the stale An issue that hasn't been active for a while... label Mar 5, 2021
@ghost
Copy link
Author

ghost commented Mar 8, 2021

The issue still persists and should be fixed/implemented.

@stale stale bot removed the stale An issue that hasn't been active for a while... label Mar 8, 2021
@roman-r-m roman-r-m added backlog We'll get to it... eventually... medium Medium priority issues desktop All desktop platforms labels Mar 25, 2021
@mightomi
Copy link

mightomi commented Mar 28, 2021

I looked into this issue, I found that ![some pdf](some.pdf) won't work since markdown doesn't support PDF.
And also something like <embed src="some.pdf" type="application/pdf"> wont work because of directory issue.
@ab791520b4 can you share how you were adding the .pdf to the markdown.

@roman-r-m
Copy link
Collaborator

@ab791520b4 can you share how you were adding the .pdf to the markdown.

Just a guess but probably something like [](file://path/to/file.pdf)

@ghost
Copy link
Author

ghost commented Mar 29, 2021

I am trying to import Markdown files as I get them via the Gitlab API [1]. I am trying to import Gitlab issue comments I exported to a local directory tree. The way gitlab stores links to attached files is

[something](/uploads/subdir/filename.extension)

I store the files analogously in the directory I am trying to import into Joplin. Meaning there exists a top-level uploads directory in the directory to import. This should work imho as it does for images.

[1] https://docs.gitlab.com/ee/api/notes.html#list-project-issue-notes

@ron-debajyoti
Copy link

Perhaps this issue is similar and can resolve the current issue.

@ghost
Copy link
Author

ghost commented Apr 6, 2021

I created a small example directory for importing:

joplin-import-test.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog We'll get to it... eventually... bug It's a bug desktop All desktop platforms medium Medium priority issues
Projects
None yet
Development

No branches or pull requests

3 participants