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

[Danbooru] Returns original gallery not as external source instead. #1863

Closed
gphg opened this issue Sep 17, 2021 · 4 comments
Closed

[Danbooru] Returns original gallery not as external source instead. #1863

gphg opened this issue Sep 17, 2021 · 4 comments

Comments

@gphg
Copy link

gphg commented Sep 17, 2021

This related to this issues: #1747

The external source saved as its extractor directory, eg pixiv saves onto gallery-dl/pixiv instead gallery-dl/danbooru. I found this is quite an issues because I don't know what it was and where it was from. I expect the file saved as danbooru's.

It would be nice if there is an option for this.

@gphg gphg changed the title Returns danbooru's gallery not as external source instead. [Danbooru] Returns original gallery not as external source instead. Sep 17, 2021
@Hrxn
Copy link
Contributor

Hrxn commented Sep 17, 2021

I think using the parent-directory option set to true should do the trick.

Simply add it to the danbooru section in the config (based on the standard example conf):

        "danbooru":
        {
            "username": null,
            "password": null,
            "external": false,
            "metadata": false,
            "ugoira": false,

            "parent-directory": true
        },

@gphg
Copy link
Author

gphg commented Sep 17, 2021

I'm going to test above. Btw, I have danbooru a custom directory. It uses file's md5 to prevent duplication and easy to search (eg, enter md5:fc9fb2ffbdc0ef08a9175402a34cc33b on search bar). This is the config:

		"danbooru": {
			"filename": "{md5}.{extension}",
			"directory": [
				"{category}",
				"{search_tags}"
			]
		},

@gphg
Copy link
Author

gphg commented Sep 17, 2021

I found it's going to be tricky or some things might break because a source is a pixiv artworks link and it may has multiple images. I'm thinking about how the filename going to be.

Above is {md5} it was from Danbooru's data. Does gallery-dl has build-in file hashing?

@mikf
Copy link
Owner

mikf commented Dec 3, 2022

Above is {md5} it was from Danbooru's data. Does gallery-dl has build-in file hashing?

It does not, but you can access the metadata from a parent extractor and use {md5} from there: parent-metadata

@mikf mikf closed this as completed Dec 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants