Skip to content

Fast application that generates Anki cards from markdown files

License

Notifications You must be signed in to change notification settings

viniciusmuller/brilho

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Brilho 🌟

Brilho is a fast application that converts markdown files to Anki cards.

Setup

With Nix

nix run github:arcticlimer/brilho --target <directory>

With cargo

cargo build --release
./target/release/brilho --target <directory>

Usage

Currently brilho expects your markdown to be in a format similar to that

Even though you don't follow this specific format, brilho tries its best to make markdown written in a similar way to look nice as Anki cards.

Showcase

Shows brilho's usage overview

After the csv file is generated, you can just go into Anki and import it in the Import tab.

Remember to enable HTML when importing

Benchmarks

Some simple benchmarks were made using this repository.

Brilho (4.1 milliseconds)

[nix-shell:~/projects/brilho]$ hyperfine "./target/release/brilho --target ../leetcode_anki/"
Benchmark #1: ./target/release/brilho --target ../leetcode_anki/
  Time (mean ± σ):       4.1 ms ±   0.6 ms    [User: 3.0 ms, System: 4.8 ms]
  Range (min … max):     2.8 ms …   5.8 ms    390 runs

Mdanki (4.5 seconds)

[nix-shell:/tmp/stub/node_modules/mdanki]$ hyperfine "./src/index.js ~/projects/leetcode_anki/ ./result.apkg"
Benchmark #1: ./src/index.js ~/projects/leetcode_anki/ ./result.apkg
  Time (mean ± σ):      4.540 s ±  0.271 s    [User: 2.614 s, System: 0.097 s]
  Range (min … max):    4.318 s …  5.056 s    10 runs

Note: mdanki was running with the memory limit workaround.

Philosophy

  • It should stick to supporting mainly common markdown files
  • It should be fast and give you a chance to review its output
  • It should be minimal and only convert markdown files into anki cards

Planned features

  • Images support
  • LaTeX support
  • URLs support
  • Backlink support
  • Use nested headings context in generated cards
  • Tests
  • Logging

Contributing

Feel free to open issues and pull requests!

If you want to help with development, you can access the Nix development environment by running the nix develop command.

About

Fast application that generates Anki cards from markdown files

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published