diff --git a/868-mhz/asphaltspur.cover.jpg b/868-mhz/asphaltspur.cover.jpg new file mode 100644 index 0000000..fb3ee67 Binary files /dev/null and b/868-mhz/asphaltspur.cover.jpg differ diff --git a/Makefile b/Makefile index a18979c..34ea042 100644 --- a/Makefile +++ b/Makefile @@ -2,4 +2,12 @@ index.json: index.html python3 scripts/extract_rdf.py > $@ index_titles.html: index.json scripts/templates/index_titles.html scripts/index_new.py - python3 scripts/index_new.py \ No newline at end of file + python3 scripts/index_new.py + +venv/: + python3 -m venv venv + source venv/bin/activate + pip install html5lib jinja2 rdflib pyrdfa3 + +merge.json: index.json covers.json + python3 scripts/merge_json.py index.json covers.json > $@ diff --git a/RuralComputing/pdf/thesis.cover.jpg b/RuralComputing/pdf/thesis.cover.jpg new file mode 100644 index 0000000..8a9373a Binary files /dev/null and b/RuralComputing/pdf/thesis.cover.jpg differ diff --git a/alt-reality-lexicon/pdf/Publication-AltRealityLexBook.cover.jpg b/alt-reality-lexicon/pdf/Publication-AltRealityLexBook.cover.jpg new file mode 100644 index 0000000..aa68703 Binary files /dev/null and b/alt-reality-lexicon/pdf/Publication-AltRealityLexBook.cover.jpg differ diff --git a/anomolous-faces/pdf/Publication-POD_Thesis_Max-Franklin.cover.jpg b/anomolous-faces/pdf/Publication-POD_Thesis_Max-Franklin.cover.jpg new file mode 100644 index 0000000..9a3506f Binary files /dev/null and b/anomolous-faces/pdf/Publication-POD_Thesis_Max-Franklin.cover.jpg differ diff --git a/attempting-diffraction/pdf/Camilo_Garcia_Aycardi_Graduation_Thesis_XPUB_.cover.jpg b/attempting-diffraction/pdf/Camilo_Garcia_Aycardi_Graduation_Thesis_XPUB_.cover.jpg new file mode 100644 index 0000000..96008e0 Binary files /dev/null and b/attempting-diffraction/pdf/Camilo_Garcia_Aycardi_Graduation_Thesis_XPUB_.cover.jpg differ diff --git a/back-it-up/pdf/Publication-Karina_ABC_thesis.cover.jpg b/back-it-up/pdf/Publication-Karina_ABC_thesis.cover.jpg new file mode 100644 index 0000000..92eff80 Binary files /dev/null and b/back-it-up/pdf/Publication-Karina_ABC_thesis.cover.jpg differ diff --git a/cartographies-of-counter-speculation/pdf/garcia-paloma-cartographies-of-invisibility.cover.jpg b/cartographies-of-counter-speculation/pdf/garcia-paloma-cartographies-of-invisibility.cover.jpg new file mode 100644 index 0000000..648b723 Binary files /dev/null and b/cartographies-of-counter-speculation/pdf/garcia-paloma-cartographies-of-invisibility.cover.jpg differ diff --git a/covers.json b/covers.json new file mode 100644 index 0000000..a1055e2 --- /dev/null +++ b/covers.json @@ -0,0 +1,205 @@ +{ + "@context": "https://xpub.nl/contexts/projects.json", + "@graph": [ + { + "cover": "https://project.xpub.nl/thanks_for_listening/thesis_mitsitron.cover.jpg", + "url": "https://project.xpub.nl/thanks_for_listening/" + }, + { + "cover": "https://project.xpub.nl/terrafying-hear-say/pdf/thesis.cover.jpg", + "url": "https://project.xpub.nl/terrafying-hear-say/" + }, + { + "cover": "https://project.xpub.nl/alt-reality-lexicon/pdf/Publication-AltRealityLexBook.cover.jpg", + "url": "https://project.xpub.nl/alt-reality-lexicon/" + }, + { + "cover": "https://project.xpub.nl/sound-jams/alnik-xpub-thesis.cover.jpg", + "url": "https://project.xpub.nl/sound-jams/" + }, + { + "cover": "https://project.xpub.nl/usx/Nami%20Kim_graduation%20thesis_Xpub.cover.jpg", + "url": "https://project.xpub.nl/usx/" + }, + { + "cover": "https://project.xpub.nl/minor_stories/pdf/%28compressed%29_spark%28l%29ing_curiosities_through_intimate_publishing.cover.jpg", + "url": "https://project.xpub.nl/minor_stories/" + }, + { + "cover": "https://project.xpub.nl/lever_burns/pdf/Ezn_LeverBurns.cover.jpg", + "url": "https://project.xpub.nl/lever_burns/" + }, + { + "cover": "https://project.xpub.nl/desire_revolution/pdf/A%20SAILORS%20GUIDE%20TO%20EARTH_Clara%20Noseda.cover.jpg", + "url": "https://project.xpub.nl/desire_revolution/" + }, + { + "cover": "https://project.xpub.nl/habitat/Thesis--Habitat--Living-sharing-adapting---Jacopo-Lega.cover.jpg", + "url": "https://project.xpub.nl/habitat/" + }, + { + "cover": "https://project.xpub.nl/referendum-medialogs/pdf/Publication-referendum_medialogs.cover.jpg", + "url": "https://project.xpub.nl/referendum-medialogs/" + }, + { + "cover": "https://project.xpub.nl/low-tech-chronicles/PDF/Mark_van_den_Heuvel_thesis_light-edition.cover.jpg", + "url": "https://project.xpub.nl/low-tech-chronicles/" + }, + { + "cover": "https://project.xpub.nl/the-constitution/pdf/Tisa-Ne%C5%BEa-Herlec_The-Constitution.cover.jpg", + "url": "https://project.xpub.nl/the-constitution/" + }, + { + "cover": "https://project.xpub.nl/when-you-might-go-astray/pdf/wymga.cover.jpg", + "url": "https://project.xpub.nl/when-you-might-go-astray/" + }, + { + "cover": "https://project.xpub.nl/howtobeasocialjusticewarrior/img/Masterthesis_MiriamSch%C3%B6b_TheLeftCanMeme.cover.jpg", + "url": "https://project.xpub.nl/howtobeasocialjusticewarrior/" + }, + { + "cover": "https://project.xpub.nl/sobremesa/pdf/thesis.cover.jpg", + "url": "https://project.xpub.nl/sobremesa/" + }, + { + "cover": "https://project.xpub.nl/cartographies-of-counter-speculation/pdf/garcia-paloma-cartographies-of-invisibility.cover.jpg", + "url": "https://project.xpub.nl/cartographies-of-counter-speculation/" + }, + { + "cover": "https://project.xpub.nl/smart-speaker-theatre/pdf/ghost_in_the_speaker.cover.jpg", + "url": "https://project.xpub.nl/smart-speaker-theatre/" + }, + { + "cover": "https://project.xpub.nl/lets-amplify-unspeakable-things/pdf/diakrousi-lets-amplify-unspeakable-things.cover.jpg", + "url": "https://project.xpub.nl/lets-amplify-unspeakable-things/" + }, + { + "cover": "https://project.xpub.nl/parallel-colonialism/pdf/bohye-woo-thesis-2020.cover.jpg", + "url": "https://project.xpub.nl/parallel-colonialism/" + }, + { + "cover": "https://project.xpub.nl/notitleyet/pdf/Martin_Foucaut_Graduation_Thesis_XPUB_2022.cover.jpg", + "url": "https://project.xpub.nl/notitleyet/" + }, + { + "cover": "https://project.xpub.nl/hacking-maintenance-with-care/pdf/HMWC.cover.jpg", + "url": "https://project.xpub.nl/hacking-maintenance-with-care/" + }, + { + "cover": "https://project.xpub.nl/how-to-make-a-notebook-that/Thesis-Paper-Notebooks.cover.jpg", + "url": "https://project.xpub.nl/how-to-make-a-notebook-that/" + }, + { + "cover": "https://project.xpub.nl/the-bootleg-library/pdf/thesis.cover.jpg", + "url": "https://project.xpub.nl/the-bootleg-library/" + }, + { + "cover": "https://project.xpub.nl/unpublishing/pdf/Thesis-N.Rotem-Stibbe.cover.jpg", + "url": "https://project.xpub.nl/unpublishing/" + }, + { + "cover": "https://project.xpub.nl/eigengrau/pdf/Phantasmagoria_Zalan_Szakacs_Thesis.cover.jpg", + "url": "https://project.xpub.nl/eigengrau/" + }, + { + "cover": "https://project.xpub.nl/tactical-watermarks/pdf/Thesis_Master_PSC_HD.cover.jpg", + "url": "https://project.xpub.nl/tactical-watermarks/" + }, + { + "cover": "https://project.xpub.nl/nothanks/pdf/THESIS-compressed.cover.jpg", + "url": "https://project.xpub.nl/nothanks/" + }, + { + "cover": "https://project.xpub.nl/networks-of-care/pdf/networksofcare_thesis.cover.jpg", + "url": "https://project.xpub.nl/networks-of-care/" + }, + { + "cover": "https://project.xpub.nl/anomolous-faces/pdf/Publication-POD_Thesis_Max-Franklin.cover.jpg", + "url": "https://project.xpub.nl/anomolous-faces/" + }, + { + "cover": "https://project.xpub.nl/back-it-up/pdf/Publication-Karina_ABC_thesis.cover.jpg", + "url": "https://project.xpub.nl/back-it-up/" + }, + { + "cover": "https://project.xpub.nl/frabjousish/pdf/thesis.cover.jpg", + "url": "https://project.xpub.nl/frabjousish/" + }, + { + "cover": "https://project.xpub.nl/dear-cross-maker/supi_Cross-Making.cover.jpg", + "url": "https://project.xpub.nl/dear-cross-maker/" + }, + { + "cover": "https://project.xpub.nl/is-it-time-to-eat-or-is-there-no-more-time-to-eat/pdf/your-body-will-make-itself-heard.cover.jpg", + "url": "https://project.xpub.nl/is-it-time-to-eat-or-is-there-no-more-time-to-eat/" + }, + { + "cover": "https://project.xpub.nl/unlearning-the-rules-of-collectivity/pdf/Publication-thesis%20Giuliade%20Giovanelli.cover.jpg", + "url": "https://project.xpub.nl/unlearning-the-rules-of-collectivity/" + }, + { + "cover": "https://project.xpub.nl/generatingstories/thesis.cover.jpg", + "url": "https://project.xpub.nl/generatingstories/" + }, + { + "cover": "https://project.xpub.nl/ilinx/pdf/OHE.cover.jpg", + "url": "https://project.xpub.nl/ilinx/" + }, + { + "cover": "https://project.xpub.nl/hello-worlding/Hello%20Worlding%20-%20kamo%20-%20THE%20REAL%20ONE.cover.jpg", + "url": "https://project.xpub.nl/hello-worlding/" + }, + { + "cover": "https://project.xpub.nl/social-shelves-project/xpub_master-thesis_gersande-schellinx.cover.jpg", + "url": "https://project.xpub.nl/social-shelves-project/" + }, + { + "cover": "https://project.xpub.nl/syster-papyri-magicae/pdf/ArtemisGryllaki-Thesis.cover.jpg", + "url": "https://project.xpub.nl/syster-papyri-magicae/" + }, + { + "cover": "https://project.xpub.nl/the-repeater-archive/pdf/Biyi_Wen_Thesis.cover.jpg", + "url": "https://project.xpub.nl/the-repeater-archive/" + }, + { + "cover": "https://project.xpub.nl/to-whom-it-may-affect/somewhere-highway-publishing.cover.jpg", + "url": "https://project.xpub.nl/to-whom-it-may-affect/" + }, + { + "cover": "https://project.xpub.nl/868-mhz/asphaltspur.cover.jpg", + "url": "https://project.xpub.nl/868-mhz/" + }, + { + "cover": "https://project.xpub.nl/modular-matter/modular-matter-Jian_Haake.cover.jpg", + "url": "https://project.xpub.nl/modular-matter/" + }, + { + "cover": "https://project.xpub.nl/instant-warnet/pdf/Berting-Making-Silences-On-Social-Media.cover.jpg", + "url": "https://project.xpub.nl/instant-warnet/" + }, + { + "cover": "https://project.xpub.nl/writing_cure/pdf/Avital_Barkai_thesis_compressed.cover.jpg", + "url": "https://project.xpub.nl/writing_cure/" + }, + { + "cover": "https://project.xpub.nl/RuralComputing/pdf/thesis.cover.jpg", + "url": "https://project.xpub.nl/RuralComputing/" + }, + { + "cover": "https://project.xpub.nl/makeinclusivewebsites/pdf/MaxLehmann_Thesis_compressed.cover.jpg", + "url": "https://project.xpub.nl/makeinclusivewebsites/" + }, + { + "cover": "https://project.xpub.nl/poetic-software/pdf/poetic_software_thesis.cover.jpg", + "url": "https://project.xpub.nl/poetic-software/" + }, + { + "cover": "https://project.xpub.nl/virtualgarden/XPUB-Cyberhotels-KB.cover.jpg", + "url": "https://project.xpub.nl/virtualgarden/" + }, + { + "cover": "https://project.xpub.nl/attempting-diffraction/pdf/Camilo_Garcia_Aycardi_Graduation_Thesis_XPUB_.cover.jpg", + "url": "https://project.xpub.nl/attempting-diffraction/" + } + ] +} diff --git a/dear-cross-maker/supi_Cross-Making.cover.jpg b/dear-cross-maker/supi_Cross-Making.cover.jpg new file mode 100644 index 0000000..2e11dec Binary files /dev/null and b/dear-cross-maker/supi_Cross-Making.cover.jpg differ diff --git a/desire_revolution/pdf/A SAILORS GUIDE TO EARTH_Clara Noseda.cover.jpg b/desire_revolution/pdf/A SAILORS GUIDE TO EARTH_Clara Noseda.cover.jpg new file mode 100644 index 0000000..42582cb Binary files /dev/null and b/desire_revolution/pdf/A SAILORS GUIDE TO EARTH_Clara Noseda.cover.jpg differ diff --git a/eigengrau/pdf/Phantasmagoria_Zalan_Szakacs_Thesis.cover.jpg b/eigengrau/pdf/Phantasmagoria_Zalan_Szakacs_Thesis.cover.jpg new file mode 100644 index 0000000..ff336d5 Binary files /dev/null and b/eigengrau/pdf/Phantasmagoria_Zalan_Szakacs_Thesis.cover.jpg differ diff --git a/frabjousish/pdf/thesis.cover.jpg b/frabjousish/pdf/thesis.cover.jpg new file mode 100644 index 0000000..1f302d6 Binary files /dev/null and b/frabjousish/pdf/thesis.cover.jpg differ diff --git a/generatingstories/thesis.cover.jpg b/generatingstories/thesis.cover.jpg new file mode 100644 index 0000000..79ba6da Binary files /dev/null and b/generatingstories/thesis.cover.jpg differ diff --git a/habitat/Thesis--Habitat--Living-sharing-adapting---Jacopo-Lega.cover.jpg b/habitat/Thesis--Habitat--Living-sharing-adapting---Jacopo-Lega.cover.jpg new file mode 100644 index 0000000..8fe42c7 Binary files /dev/null and b/habitat/Thesis--Habitat--Living-sharing-adapting---Jacopo-Lega.cover.jpg differ diff --git a/hacking-maintenance-with-care/pdf/HMWC.cover.jpg b/hacking-maintenance-with-care/pdf/HMWC.cover.jpg new file mode 100644 index 0000000..871ee72 Binary files /dev/null and b/hacking-maintenance-with-care/pdf/HMWC.cover.jpg differ diff --git a/hello-worlding/Hello Worlding - kamo - THE REAL ONE.cover.jpg b/hello-worlding/Hello Worlding - kamo - THE REAL ONE.cover.jpg new file mode 100644 index 0000000..f35b0ca Binary files /dev/null and b/hello-worlding/Hello Worlding - kamo - THE REAL ONE.cover.jpg differ diff --git a/how-to-make-a-notebook-that/Thesis-Paper-Notebooks.cover.jpg b/how-to-make-a-notebook-that/Thesis-Paper-Notebooks.cover.jpg new file mode 100644 index 0000000..a042b6b Binary files /dev/null and b/how-to-make-a-notebook-that/Thesis-Paper-Notebooks.cover.jpg differ diff --git a/howtobeasocialjusticewarrior/img/Masterthesis_MiriamSchöb_TheLeftCanMeme.cover.jpg b/howtobeasocialjusticewarrior/img/Masterthesis_MiriamSchöb_TheLeftCanMeme.cover.jpg new file mode 100644 index 0000000..3265f0a Binary files /dev/null and b/howtobeasocialjusticewarrior/img/Masterthesis_MiriamSchöb_TheLeftCanMeme.cover.jpg differ diff --git a/ilinx/pdf/OHE.cover.jpg b/ilinx/pdf/OHE.cover.jpg new file mode 100644 index 0000000..13c5f20 Binary files /dev/null and b/ilinx/pdf/OHE.cover.jpg differ diff --git a/instant-warnet/pdf/Berting-Making-Silences-On-Social-Media.cover.jpg b/instant-warnet/pdf/Berting-Making-Silences-On-Social-Media.cover.jpg new file mode 100644 index 0000000..83bdce3 Binary files /dev/null and b/instant-warnet/pdf/Berting-Making-Silences-On-Social-Media.cover.jpg differ diff --git a/is-it-time-to-eat-or-is-there-no-more-time-to-eat/pdf/your-body-will-make-itself-heard.cover.jpg b/is-it-time-to-eat-or-is-there-no-more-time-to-eat/pdf/your-body-will-make-itself-heard.cover.jpg new file mode 100644 index 0000000..f61ade7 Binary files /dev/null and b/is-it-time-to-eat-or-is-there-no-more-time-to-eat/pdf/your-body-will-make-itself-heard.cover.jpg differ diff --git a/lets-amplify-unspeakable-things/pdf/diakrousi-lets-amplify-unspeakable-things.cover.jpg b/lets-amplify-unspeakable-things/pdf/diakrousi-lets-amplify-unspeakable-things.cover.jpg new file mode 100644 index 0000000..1d60deb Binary files /dev/null and b/lets-amplify-unspeakable-things/pdf/diakrousi-lets-amplify-unspeakable-things.cover.jpg differ diff --git a/lever_burns/pdf/Ezn_LeverBurns.cover.jpg b/lever_burns/pdf/Ezn_LeverBurns.cover.jpg new file mode 100644 index 0000000..299dd77 Binary files /dev/null and b/lever_burns/pdf/Ezn_LeverBurns.cover.jpg differ diff --git a/low-tech-chronicles/PDF/Mark_van_den_Heuvel_thesis_light-edition.cover.jpg b/low-tech-chronicles/PDF/Mark_van_den_Heuvel_thesis_light-edition.cover.jpg new file mode 100644 index 0000000..a370dd5 Binary files /dev/null and b/low-tech-chronicles/PDF/Mark_van_den_Heuvel_thesis_light-edition.cover.jpg differ diff --git a/makeinclusivewebsites/pdf/MaxLehmann_Thesis_compressed.cover.jpg b/makeinclusivewebsites/pdf/MaxLehmann_Thesis_compressed.cover.jpg new file mode 100644 index 0000000..e2e6e8e Binary files /dev/null and b/makeinclusivewebsites/pdf/MaxLehmann_Thesis_compressed.cover.jpg differ diff --git a/minor_stories/pdf/(compressed)_spark(l)ing_curiosities_through_intimate_publishing.cover.jpg b/minor_stories/pdf/(compressed)_spark(l)ing_curiosities_through_intimate_publishing.cover.jpg new file mode 100644 index 0000000..9d35401 Binary files /dev/null and b/minor_stories/pdf/(compressed)_spark(l)ing_curiosities_through_intimate_publishing.cover.jpg differ diff --git a/modular-matter/modular-matter-Jian_Haake.cover.jpg b/modular-matter/modular-matter-Jian_Haake.cover.jpg new file mode 100644 index 0000000..1082061 Binary files /dev/null and b/modular-matter/modular-matter-Jian_Haake.cover.jpg differ diff --git a/networks-of-care/pdf/networksofcare_thesis.cover.jpg b/networks-of-care/pdf/networksofcare_thesis.cover.jpg new file mode 100644 index 0000000..3394222 Binary files /dev/null and b/networks-of-care/pdf/networksofcare_thesis.cover.jpg differ diff --git a/nothanks/pdf/THESIS-compressed.cover.jpg b/nothanks/pdf/THESIS-compressed.cover.jpg new file mode 100644 index 0000000..558917d Binary files /dev/null and b/nothanks/pdf/THESIS-compressed.cover.jpg differ diff --git a/notitleyet/pdf/Martin_Foucaut_Graduation_Thesis_XPUB_2022.cover.jpg b/notitleyet/pdf/Martin_Foucaut_Graduation_Thesis_XPUB_2022.cover.jpg new file mode 100644 index 0000000..86ef642 Binary files /dev/null and b/notitleyet/pdf/Martin_Foucaut_Graduation_Thesis_XPUB_2022.cover.jpg differ diff --git a/poetic-software/pdf/poetic_software_thesis.cover.jpg b/poetic-software/pdf/poetic_software_thesis.cover.jpg new file mode 100644 index 0000000..30a0af3 Binary files /dev/null and b/poetic-software/pdf/poetic_software_thesis.cover.jpg differ diff --git a/referendum-medialogs/pdf/Publication-referendum_medialogs.cover.jpg b/referendum-medialogs/pdf/Publication-referendum_medialogs.cover.jpg new file mode 100644 index 0000000..a691aab Binary files /dev/null and b/referendum-medialogs/pdf/Publication-referendum_medialogs.cover.jpg differ diff --git a/scripts/generate_pdf_covers.py b/scripts/generate_pdf_covers.py new file mode 100644 index 0000000..0cdd5e4 --- /dev/null +++ b/scripts/generate_pdf_covers.py @@ -0,0 +1,55 @@ +from pathlib import Path +from common import load_json +from urllib.parse import urlparse, quote as urlquote, unquote as urlunquote +from rdflib import Graph, Namespace, RDF, DCTERMS, URIRef +import subprocess + + +XPUB = Namespace("http://xpub.nl/terms/") + +def url_to_path (url): + parts = urlparse(url) + if parts.hostname == "project.xpub.nl": + path = urlunquote(parts.path.lstrip('/')) + return Path(path) + +def path_to_url(path): + return "https://project.xpub.nl/" + urlquote(str(path)) + +def make_cover (inpath, outpath, page=1): + p = subprocess.run(["gs", "-dSAFER", "-r600", "-sDEVICE=jpeg", f"-dFirstPage={page}", f"-dLastPage={page}", "-o", outpath, inpath]) + if p.returncode == 0: + p = subprocess.run(["mogrify", "-resize", "640x", outpath]) + return p.returncode == 0 + + +g = Graph() +data = load_json() +for project in data['projects']: + print (project['thesis']) + p = url_to_path(project['thesis']) + cover_path = p.parent / (p.stem + ".cover.jpg") + g.add((URIRef(project['url']), XPUB['cover'], URIRef(path_to_url(cover_path)))) + print (f" {p}->{cover_path}") + if not cover_path.exists(): + make_cover(p, cover_path) + +with open("covers.json", "w") as fout: + # print (g.serialize(), file=fout) + print (g.serialize(format="json-ld", context="https://xpub.nl/contexts/projects.json"), file=fout) + + +# from generated_covers import books_with_generated_covers +# import subprocess +# from shutil import copyfile + +# for dbid, path in books_with_generated_covers("calibre"): +# for pdf in path.glob("*.pdf"): +# print (pdf) +# # gs -dSAFER -r600 -sDEVICE=jpeg -dFirstPage=2 -dLastPage=2 -o cover.jpg test.pdf && mogrify -resize 640x cover.jpg + +# # gs -dSAFER -r600 -sDEVICE=jpeg -dLastPage=1 -o cover.jpg "calibre/Michael Moss/To talk of many things_ Of shoes--and ships--and sealing-wax--Of cabbages--and kings- (85)/To talk of many things_ Of shoes--and ship - Michael Moss.pdf" +# subprocess.run(["gs", "-dSAFER", "-r600", "-sDEVICE=jpeg", "-dLastPage=1", "-o", "cover.jpg", str(pdf)]) +# subprocess.run(["mogrify", "-resize", "1200x", "cover.jpg"]) +# subprocess.run(["exiftool", "-Comment=Generated cover: gs/pdffirstpage", "cover.jpg"]) +# copyfile("cover.jpg", path / "cover.jpg") diff --git a/scripts/merge_json.py b/scripts/merge_json.py new file mode 100644 index 0000000..c562b05 --- /dev/null +++ b/scripts/merge_json.py @@ -0,0 +1,22 @@ +import rdflib +import json +import argparse + + +ap = argparse.ArgumentParser("") +ap.add_argument("input", nargs="+") +args = ap.parse_args() + +context = None +u = rdflib.Graph() +for i in args.input: + if context is None: + with open(i) as fin: + data = json.load(fin) + if '@context' in data: + context = data['@context'] + g = rdflib.Graph() + g.parse(i) + u += g + +print (u.serialize(format="json-ld", context=context)) \ No newline at end of file diff --git a/scripts/projects.json b/scripts/projects.json index f02b701..ad3b84a 100644 --- a/scripts/projects.json +++ b/scripts/projects.json @@ -14,6 +14,7 @@ "url": {"@id": "@id", "@type": "@id"}, "type": {"@id": "@type", "@type": "@id"}, "links": {"@id": "dc:link", "@type": "@id"}, - "nicknames": "xpub:nick" + "nicknames": "xpub:nick", + "cover": { "@id": "xpub:cover", "@type": "@id" } } } diff --git a/smart-speaker-theatre/pdf/ghost_in_the_speaker.cover.jpg b/smart-speaker-theatre/pdf/ghost_in_the_speaker.cover.jpg new file mode 100644 index 0000000..e3949a6 Binary files /dev/null and b/smart-speaker-theatre/pdf/ghost_in_the_speaker.cover.jpg differ diff --git a/sobremesa/pdf/thesis.cover.jpg b/sobremesa/pdf/thesis.cover.jpg new file mode 100644 index 0000000..ad7b4a2 Binary files /dev/null and b/sobremesa/pdf/thesis.cover.jpg differ diff --git a/social-shelves-project/xpub_master-thesis_gersande-schellinx.cover.jpg b/social-shelves-project/xpub_master-thesis_gersande-schellinx.cover.jpg new file mode 100644 index 0000000..98b77ad Binary files /dev/null and b/social-shelves-project/xpub_master-thesis_gersande-schellinx.cover.jpg differ diff --git a/sound-jams/alnik-xpub-thesis.cover.jpg b/sound-jams/alnik-xpub-thesis.cover.jpg new file mode 100644 index 0000000..a0e9934 Binary files /dev/null and b/sound-jams/alnik-xpub-thesis.cover.jpg differ diff --git a/syster-papyri-magicae/pdf/ArtemisGryllaki-Thesis.cover.jpg b/syster-papyri-magicae/pdf/ArtemisGryllaki-Thesis.cover.jpg new file mode 100644 index 0000000..6da5b42 Binary files /dev/null and b/syster-papyri-magicae/pdf/ArtemisGryllaki-Thesis.cover.jpg differ diff --git a/tactical-watermarks/pdf/Thesis_Master_PSC_HD.cover.jpg b/tactical-watermarks/pdf/Thesis_Master_PSC_HD.cover.jpg new file mode 100644 index 0000000..007fc53 Binary files /dev/null and b/tactical-watermarks/pdf/Thesis_Master_PSC_HD.cover.jpg differ diff --git a/terrafying-hear-say/pdf/thesis.cover.jpg b/terrafying-hear-say/pdf/thesis.cover.jpg new file mode 100644 index 0000000..36afab7 Binary files /dev/null and b/terrafying-hear-say/pdf/thesis.cover.jpg differ diff --git a/thanks_for_listening/thesis_mitsitron.cover.jpg b/thanks_for_listening/thesis_mitsitron.cover.jpg new file mode 100644 index 0000000..b26e8d6 Binary files /dev/null and b/thanks_for_listening/thesis_mitsitron.cover.jpg differ diff --git a/the-bootleg-library/pdf/thesis.cover.jpg b/the-bootleg-library/pdf/thesis.cover.jpg new file mode 100644 index 0000000..d757f6b Binary files /dev/null and b/the-bootleg-library/pdf/thesis.cover.jpg differ diff --git a/the-constitution/pdf/Tisa-Neža-Herlec_The-Constitution.cover.jpg b/the-constitution/pdf/Tisa-Neža-Herlec_The-Constitution.cover.jpg new file mode 100644 index 0000000..f8edab8 Binary files /dev/null and b/the-constitution/pdf/Tisa-Neža-Herlec_The-Constitution.cover.jpg differ diff --git a/the-repeater-archive/pdf/Biyi_Wen_Thesis.cover.jpg b/the-repeater-archive/pdf/Biyi_Wen_Thesis.cover.jpg new file mode 100644 index 0000000..aed7532 Binary files /dev/null and b/the-repeater-archive/pdf/Biyi_Wen_Thesis.cover.jpg differ diff --git a/to-whom-it-may-affect/somewhere-highway-publishing.cover.jpg b/to-whom-it-may-affect/somewhere-highway-publishing.cover.jpg new file mode 100644 index 0000000..fb5b3db Binary files /dev/null and b/to-whom-it-may-affect/somewhere-highway-publishing.cover.jpg differ diff --git a/unlearning-the-rules-of-collectivity/pdf/Publication-thesis Giuliade Giovanelli.cover.jpg b/unlearning-the-rules-of-collectivity/pdf/Publication-thesis Giuliade Giovanelli.cover.jpg new file mode 100644 index 0000000..836f67c Binary files /dev/null and b/unlearning-the-rules-of-collectivity/pdf/Publication-thesis Giuliade Giovanelli.cover.jpg differ diff --git a/unpublishing/pdf/Thesis-N.Rotem-Stibbe.cover.jpg b/unpublishing/pdf/Thesis-N.Rotem-Stibbe.cover.jpg new file mode 100644 index 0000000..8c88121 Binary files /dev/null and b/unpublishing/pdf/Thesis-N.Rotem-Stibbe.cover.jpg differ diff --git a/usx/Nami Kim_graduation thesis_Xpub.cover.jpg b/usx/Nami Kim_graduation thesis_Xpub.cover.jpg new file mode 100644 index 0000000..f50e0bc Binary files /dev/null and b/usx/Nami Kim_graduation thesis_Xpub.cover.jpg differ diff --git a/virtualgarden/XPUB-Cyberhotels-KB.cover.jpg b/virtualgarden/XPUB-Cyberhotels-KB.cover.jpg new file mode 100644 index 0000000..e75d16b Binary files /dev/null and b/virtualgarden/XPUB-Cyberhotels-KB.cover.jpg differ diff --git a/when-you-might-go-astray/pdf/wymga.cover.jpg b/when-you-might-go-astray/pdf/wymga.cover.jpg new file mode 100644 index 0000000..dc3a2df Binary files /dev/null and b/when-you-might-go-astray/pdf/wymga.cover.jpg differ diff --git a/writing_cure/pdf/Avital_Barkai_thesis_compressed.cover.jpg b/writing_cure/pdf/Avital_Barkai_thesis_compressed.cover.jpg new file mode 100644 index 0000000..7239e81 Binary files /dev/null and b/writing_cure/pdf/Avital_Barkai_thesis_compressed.cover.jpg differ