Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Enhancement]: Append tags from OPF file #602

Closed
plague-doctor opened this issue May 18, 2022 · 6 comments
Closed

[Enhancement]: Append tags from OPF file #602

plague-doctor opened this issue May 18, 2022 · 6 comments
Labels
enhancement New feature or request

Comments

@plague-doctor
Copy link

Describe the feature/enhancement

As audiobookshelf supports Tags, can we please add tags from OPF file?

I work on a scraper to generate OPF file for my audiobooks collection. I would love to be able to add the tags from opf automatically.

An example of my metadata.opf file looks like that:

<?xml version='1.0' encoding='utf-8'?>
<ns0:package xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:ns0="http://www.idpf.org/2007/opf" version="2.0">
	<ns0:metadata>
		<dc:title>Narrenturm</dc:title>
		<dc:creator ns0:role="aut">Andrzej Sapkowski</dc:creator>
		<dc:creator ns0:role="nrt">zespół lektorów</dc:creator>
		<dc:date />
		<dc:publisher />
		<dc:identifier ns0:scheme="ISBN" />
		<dc:description>
Świat nie zginął i nie spłonął. Przynajmniej nie cały. 
Ale i tak było wesoło. 
[...] 
Przed nami jeszcze dwa tomy trylogii. </dc:description>
		<dc:language>pol</dc:language>
		<ns0:meta name="calibre:series" content="Trylogia husycka" />
		<ns0:meta name="calibre:series_index" content="1" />
		<dc:subject>fantasy</dc:subject>
		<dc:subject>science fiction</dc:subject>
		<dc:tag>Nagroda Zajdla - zwycięzca</dc:tag>
		<dc:tag>Husyci</dc:tag>
		<dc:tag>Reynewen</dc:tag>
		<dc:tag>czarna magia</dc:tag>
		<dc:tag>biała magia</dc:tag>
		<dc:tag>Śląsk</dc:tag>
	</ns0:metadata>
</ns0:package>
@plague-doctor plague-doctor added the enhancement New feature or request label May 18, 2022
advplyr added a commit that referenced this issue May 19, 2022
…or prefix on package/metadata/meta objects
@advplyr
Copy link
Owner

advplyr commented May 19, 2022

I also had to check for the ns0 prefix you are using since this wasn't supported before. Same as genres it will only set the tags if they are empty or if you have "prefer OPF metadata" toggled on.
opf-tags

@advplyr
Copy link
Owner

advplyr commented May 20, 2022

This is in v2.0.15

@neingeist
Copy link

great feature, thanks!

@mariohi
Copy link

mariohi commented Oct 8, 2023

@plague-doctor any chance you could share the code for scrapper? It looks like something I'm trying to achieve with lubimyczytac.pl

@plague-doctor
Copy link
Author

Oh, being a systems admin, my code usually should be deposited to Sèvres as an example of how not to code, ever :-)
Also, lubimy czytać frequently changes the website which renders scrapers nonoperational. I started to use audioteka.com/pl as they are more friendly.
But if you want to take a bite, there is it: plague-doctor/scraper but as I have said above - prepare yourself to be greatly underwhelmed ;-)

Oasis256 pushed a commit to Oasis256/StoryTeller that referenced this issue Jun 3, 2024
@izikeros
Copy link

Would be good to have a metadata provider either libumyczytac or audioteka. I have created feature request in issue #3105.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants