- The version you are using. => Joplin 2.6.10 (prod, linux)
- The operating system you are using. => Ubuntu 22.04.1 LTS
I am currently in a process of developing a Rust app for publishing my code from Joplin to Hugo directly. So everything is well and good except the images part. Joplin uses the following code in markdown format.
But the image filename I have found in the resources folder is
So basically Joplin take takes the extension from the first part of square brackets and combines it with the last part found in the first brackets. I could not understand the motive of this.
From what I have found, square brackets is for ALT text and first brackets is for the filename. As the filename of image is not correct and Hugo cannot find the image as it is looking for the file in first brackets.
Another issue is, the character ":" is placed between the first brackets so when I copy the content to a new file, and Hugo eventually generates the file, that extra ":" remain and no image is displayed.
Looking forward for your support so that I can finish my application
Not exactly sure what square brackets and colon you're referring to. Joplin stores images and other files using the resource id for the file name.
To get the original file name you either need to use the API or query the DB directly (not recommended unless you know what you're doing)
Thank you for your response. I have updated the question. Now you can see the brackets and ":" I am talking about.
Currently, I am accessing the DB only in readonly mode.
Taking you example:
438...75.png is the original name and extension of the file that was attached (in this case it's not much different from the id but it can be something more meaningful).
8c...5ce1 is the id of the resource corresponding to the file, it's used as a key in DB and for links, among other things.
As you have already figured out the name of the corresponding file in Joplin's storage is
:/ is used to identify Joplin internal links.
Yes when you are working from Joplin, everything is good and well. But the problem starts with when you are thinking outside joplin.
For example, if you are copying content from joplin to elsewhere, you will also have to modify your notes as well and manually append the extensions like jpg, png etc. I think joplin could have included the extension in the markdown.
I guess I will have to perform more changes in my code
Well, yes, if you do something Joplin wasn't designed for, you have to put in more work. Is this surprising?
Btw, I believe there was a plugin that could export notes to Hugo (on mobile atm so can't find the link), maybe it could be useful for you.
Well, I didn't understand the benefit of such design where you are excluding extension which was the surprising part.
Anyhow, Thank you for your help. I will make my own plugin.
I created joplin-blog, which currently supports generating hexo/vuepress/docsify/jeykll, I guess, it should be easy to integrate into hugo?
original requirements for previous jeykll support: Plugin: Generate static blog website and publish to Github Pages - #11 by pravsripad
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.