A quick and dirty note about how to export flashcards from Anki and import them in Pleco. I’m assuming some familiarity with both Anki and Pleco.
- Open your deck in Anki.
- Go to File->Export.
- Set the export format to “Facts in tab-separated text file”.
- (Optional:) Limit by tags.
- Click “Export to…”. You will have to select a file to save to.
- You then need to rearrange the output of Anki. Anki outputs its data as: Chinese TAB English TAB Pinyin. Pleco wants Chinese TAB Pinyin TAB Chinese. Any macro or script which reorders the second and third field will do the trick. I use the following:
$ gawk -F '\t' -- '{print $1"\t"$3"\t"$2}' [exported file] > [fixed file]
“[exported file]” is the file previously exported from Anki. “[fixed file]” is where to save the output.
- Shove “[fixed file]” onto a flash card or transmit it to the device running Pleco.
- In Pleco, select “Modules->Open Flashcards…”.
- 9. Click the “Import” button.
- 10. Set the following:
- Source: the file you want to import.
- Card Language: Chinese-English
- Text Encoding: UTF-8
- Missing Entries: Create Blank
- Ambiguous Entries: Prompt
- Duplicate Entries: Prompt
- Store imported defns in user dict: unchecked
- Hit start. Make sure the sample data looks good. Hit yes if it does look good.
- Exercise left to the reader: check that your cards look good after importing.