mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00

- anki._backend stores the protobuf files and rsbackend.py code - pylib modules import protobuf messages directly from the _pb2 files, and explicitly export any will be returned or consumed by public pylib functions, so that calling code can import from pylib - the "rsbackend" no longer imports and re-exports protobuf messages - pylib can just consume them directly. - move errors to errors.py Still todo: - rsbridge - finishing the work on rsbackend, and check what we need to add back to the original file location to avoid breaking add-ons
21 lines
963 B
Python
21 lines
963 B
Python
# Copyright: Ankitects Pty Ltd and contributors
|
|
# License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|
|
|
from anki.importing.anki2 import Anki2Importer
|
|
from anki.importing.apkg import AnkiPackageImporter
|
|
from anki.importing.csvfile import TextImporter
|
|
from anki.importing.mnemo import MnemosyneImporter
|
|
from anki.importing.pauker import PaukerImporter
|
|
from anki.importing.supermemo_xml import SupermemoXmlImporter # type: ignore
|
|
from anki.lang import TR, tr_legacyglobal
|
|
|
|
Importers = (
|
|
(tr_legacyglobal(TR.IMPORTING_TEXT_SEPARATED_BY_TABS_OR_SEMICOLONS), TextImporter),
|
|
(
|
|
tr_legacyglobal(TR.IMPORTING_PACKAGED_ANKI_DECKCOLLECTION_APKG_COLPKG_ZIP),
|
|
AnkiPackageImporter,
|
|
),
|
|
(tr_legacyglobal(TR.IMPORTING_MNEMOSYNE_20_DECK_DB), MnemosyneImporter),
|
|
(tr_legacyglobal(TR.IMPORTING_SUPERMEMO_XML_EXPORT_XML), SupermemoXmlImporter),
|
|
(tr_legacyglobal(TR.IMPORTING_PAUKER_18_LESSON_PAUGZ), PaukerImporter),
|
|
)
|