vault backup: 2025-11-20 07:57:06
This commit is contained in:
14
content/.obsidian/workspace.json
vendored
14
content/.obsidian/workspace.json
vendored
@@ -6,7 +6,7 @@
|
||||
{
|
||||
"id": "3f6b32748450846e",
|
||||
"type": "tabs",
|
||||
"dimension": 53.4257748776509,
|
||||
"dimension": 74.86818980667839,
|
||||
"children": [
|
||||
{
|
||||
"id": "5cd07fc76098d003",
|
||||
@@ -28,12 +28,12 @@
|
||||
"state": {
|
||||
"type": "markdown",
|
||||
"state": {
|
||||
"file": "Biokemi/!Template/Lärandemål.md",
|
||||
"file": "Studieteknik/Export all to anki.md",
|
||||
"mode": "source",
|
||||
"source": false
|
||||
},
|
||||
"icon": "lucide-file",
|
||||
"title": "Lärandemål"
|
||||
"title": "Export all to anki"
|
||||
}
|
||||
}
|
||||
],
|
||||
@@ -42,7 +42,7 @@
|
||||
{
|
||||
"id": "2f45996db37e6ccd",
|
||||
"type": "tabs",
|
||||
"dimension": 46.574225122349105,
|
||||
"dimension": 25.13181019332162,
|
||||
"children": [
|
||||
{
|
||||
"id": "e53ce881144526f0",
|
||||
@@ -203,8 +203,7 @@
|
||||
}
|
||||
],
|
||||
"direction": "horizontal",
|
||||
"width": 200,
|
||||
"collapsed": true
|
||||
"width": 200
|
||||
},
|
||||
"left-ribbon": {
|
||||
"hiddenItems": {
|
||||
@@ -220,6 +219,8 @@
|
||||
},
|
||||
"active": "06be19e869ba432d",
|
||||
"lastOpenFiles": [
|
||||
"Biokemi/!Template/Lärandemål.md",
|
||||
"Studieteknik/Export all to anki.md",
|
||||
"Biokemi/!Template/Provfrågor.md",
|
||||
"Biokemi/Cellulära processer/RNA syntes/Anteckningar.md",
|
||||
"Biokemi/Cellulära processer/Translation",
|
||||
@@ -238,7 +239,6 @@
|
||||
"Biokemi/Cellulära processer/Initiering och terminering av DNA replikation/Instuderingsfrågor.md",
|
||||
"Biokemi/Cellulära processer/Initiering och terminering av DNA replikation/Lärandemål.md",
|
||||
"Biokemi/Cellulära processer/Initiering och terminering av DNA replikation/Provfrågor.md",
|
||||
"Biokemi/!Template/Lärandemål.md",
|
||||
"Biokemi/!Template/Instuderingsfrågor.md",
|
||||
"Biokemi/!Template/Anteckningar.md",
|
||||
"Biokemi/!Template",
|
||||
|
||||
24
content/Studieteknik/Export all to anki.md
Normal file
24
content/Studieteknik/Export all to anki.md
Normal file
@@ -0,0 +1,24 @@
|
||||
|
||||
```
|
||||
#!/Users/johandahlin/Library/Application Support/AnkiProgramFiles/.venv/bin/python
|
||||
from anki.collection import Collection
|
||||
c = Collection("/Users/johandahlin/Library/Application Support/Anki2/User 1/collection.anki2")
|
||||
for deck_name in c.decks.all_names():
|
||||
if not deck_name.startswith("Biokemi::Johan D"):
|
||||
continue
|
||||
deck_name = deck_name.replace("Johan D::", "")
|
||||
deck_name = deck_name.replace("::", "_")
|
||||
deck_id = c.decks.id_for_name(d)
|
||||
c.export_anki_package(
|
||||
out_path=f"/tmp/{deck_name}.apkg",
|
||||
options=ExportAnkiPackageOptions(with_media=True),
|
||||
limit=DeckIdLimit(deck_id),
|
||||
)
|
||||
```
|
||||
|
||||
TODO
|
||||
- Update script to run rsync to moln
|
||||
- Update Caddyfile to [serve static files](https://caddyserver.com/docs/caddyfile/directives/file_server), perhaps with index
|
||||
- Generate obsidian page with links to anki that can be downloaded
|
||||
- how do we insert dynamic content?
|
||||
- low prio: run it automatically (do we want to?)
|
||||
Reference in New Issue
Block a user