lervag/apy

specifying deck when adding from file?

nathanbraun opened this issue · 3 comments

Hi Karl, got this working with my setup the other day and enjoy it so far, thanks.

I tried implementing the adding cards via Vim example you wrote up in the Wiki. It basically worked, I was wondering if it was possible to control which deck it added the cards to? I tried running it twice as a test, each time it added my cards to different deck.

I'm glad to hear you find it working!

By default, the notes will be added to the last used deck, whatever that is. You can specify the deck with the deck: name key value pair in the markdown "preamble", e.g.:

# Note
tags: marked tag1 tag2
deck: MyFancyDeck
...

I personally only use a single deck for everything, so I don't really use this myself. But I think it should work, as long as you use the correct name for the deck. It should be relatively straightforward to update the Vim scripts to either add a default deck to every generated note.

Worked perfectly, thank you!

Great, happy to hear it!