ndyag / anki-apkg Goto Github PK
View Code? Open in Web Editor NEWCreate .apkg file for Anki
License: MIT License
Create .apkg file for Anki
License: MIT License
I suggest to add a feature to generate an updated apkg that can replace the old one because most of the user do not want to lose progress (delete old apkg and import new apkg) when they need to update the cards
I tried to implement it myself but it doesn't work, here is my procedures:
I tried to generate updated apkg using existing code, it successfully import but the old content is kept too, so each cards is duplicated
I looked into the code, and saw that the cardId is actually current timestamp, which will be difference every time by default, so I set it to a fixed value. But when I import that apkg, the following error shown:
Updated 0 of 7605 existing notes.
0 cards imported.
I guess it is because mod
(createTime) is the same so the card is not updated, so I modify the code and set mod
to current time. After import, the following error is shown (I am sure only mod
is updated):
Updated 0 of 7605 existing notes.
Some updates were ignored because note type has changed:
I do not have any glue after many google search, the only apkg documentation I can find is http://decks.wikia.com/wiki/Anki_APKG_format_documentation , but it is way too minimal. @NdYAG do you have any idea?
Hi, thank you for publishing this package! Sorry for the silly question, but is it possible to use it to add a new card to an existing deck in a apkg or is it only for batch-generating new apkgs from scratch? Thank you!
When I try to npm install anki-apkg
I got this:
1 error generated.
make: *** [Release/obj.target/integer/src/integer.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
gyp ERR! System Darwin 18.7.0
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/jordandruart/fluentwithinayear/node_modules/integer
gyp ERR! node -v v14.15.1
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
npm WARN [email protected] requires a peer of @popperjs/core@^2.5.4 but none is installed. You must install peer dependencies yourself.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/jordandruart/.npm/_logs/2021-01-17T14_06_20_590Z-debug.log
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.