Git Product home page Git Product logo

Comments (14)

Nriver avatar Nriver commented on June 9, 2024

Hi, I've never tried linking files in markdown notes. Would you tell me what software you are using and provide a sample md including the file?

from trilium-py.

holoword avatar holoword commented on June 9, 2024

I just take markdown file import as an example, what i really need is ability to send a file to trilium note. since a cannot find out upload file API, but trilium restapi provide it since function create_note support type [ text, code, file, image, search, book. relationMap, render]. After a code view in this repo, I find it is easy to implement a file upload function. If I have time this weekend, I can make a pull requests.
Also, Markdown file can attach file, the grammar as like image, but when converse to html use markdown2, the html tag is different. what I most used scene is book note. when I create a book note, I'd like to attachment the file(epub|pdf) in this markdown file, when next time I read my booknote, at least I have a copy of the book.
Attachment is a simple markdown with file example in obsidian.
Obsidian Vault.zip

from trilium-py.

Nriver avatar Nriver commented on June 9, 2024

I tried to use obsidian-export to convert obsidian vault to ordinary markdown as explained here https://github.com/Nriver/trilium-py#import-from-obsidian.

But your the file in your sample does not seem to be handled properly by the tool. The square brackets in file name is causing issues like zoni/obsidian-export#14.

from trilium-py.

holoword avatar holoword commented on June 9, 2024

Sorry for the export problem and late reply. I'm experience a hard weekday. The obsidian example is just a toy and not self test.
Previously, I used Joplin which direct export markdown with file, you can try to upload.
In Monday, I have success write a function with process file upload, but currently I have no time to format it, maybe after I complete my lifework I have time.
joplinExport.zip

from trilium-py.

holoword avatar holoword commented on June 9, 2024

#11 Just add file upload function firstly, the markdown file process next time.

from trilium-py.

BARaphael avatar BARaphael commented on June 9, 2024

@Nriver Hi, since #11 has been merged, can you create a new release and update pypi?

from trilium-py.

Nriver avatar Nriver commented on June 9, 2024

I was waiting for his next pr. I will make a release anyway.

from trilium-py.

BARaphael avatar BARaphael commented on June 9, 2024

I was waiting for his next pr. I will make a release anyway.

Thanks

from trilium-py.

Nriver avatar Nriver commented on June 9, 2024

Just pushed 0.7.5 to pypi

from trilium-py.

holoword avatar holoword commented on June 9, 2024

Sorry for the late, I'm currently prepare for job interview and too busy, may I have time next weekend!

from trilium-py.

Nriver avatar Nriver commented on June 9, 2024

Good luck with your job interview.

from trilium-py.

holoword avatar holoword commented on June 9, 2024

I have finish code writing and function test. But I find some confused naming in API and parameter naming. Can you give some more parameter explanation about create function?

from trilium-py.

Nriver avatar Nriver commented on June 9, 2024

Basically I'd write with snake_case. But when it comes to the parameters defined in etapi like noteId, https://github.com/zadam/trilium/blob/7fc2824325f6a6bcbbd2e18179d69dbd4ac65d09/src/etapi/notes.js#LL80C9-L80C9, I would prefer to use the same name even if it's camelCase not the snake_case.

from trilium-py.

Nriver avatar Nriver commented on June 9, 2024

Implemented in 99d2197

from trilium-py.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.