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

auto download/ all images in one folder? #36

Closed
azzerzzzeqwe opened this issue Aug 15, 2022 · 3 comments
Closed

auto download/ all images in one folder? #36

azzerzzzeqwe opened this issue Aug 15, 2022 · 3 comments
Labels

Comments

@azzerzzzeqwe
Copy link

i want all the images of a certian tag to go into just one folder instead of each individual one, is there a way to do that?
also is there a feature to autodownload threads in the queue text file when one appears

@Exceen
Copy link
Owner

Exceen commented Aug 16, 2022

This is only possible if the threads are on the same board. If you put these two lines into your queue-file
https://boards.4chan.org/b/thread/12345678/mytag
https://boards.4chan.org/b/thread/87654321/mytag
... then all files will be placed in a folder named downloads/b/mytag if you run the main script (inb4404.py) with the -n/--use-names option. Otherwise these "tags" will be ignored.

The other thing you're asking for is the thread-watcher.py file. Let's say you want to download every "wallpaper" thread from the /hr/ board then you'd have to run the following command:

python thread-watcher.py -b hr -q wallpaper -f queue.txt -n "HR-Wallpapers"

Right now there's one thread that contains "wallpaper" on /hr/ which is https://boards.4chan.org/hr/thread/4474136

So this script basically looks on the specified board (-b) for a search term (-q). This uses 4chan's built-in search. If the search returns something, it will look into the specified file (-f) and adds the found thread if it's not already there. It will also append the name/tag (-n) "HR-Wallpapers" to the end of the URL so that everything will be placed in the same folder. So in the end the file will contain this url: https://boards.4chan.org/hr/thread/4474136/HR-Wallpapers

@azzerzzzeqwe
Copy link
Author

This is only possible if the threads are on the same board. If you put these two lines into your queue-file https://boards.4chan.org/b/thread/12345678/mytag https://boards.4chan.org/b/thread/87654321/mytag ... then all files will be placed in a folder named downloads/b/mytag if you run the main script (inb4404.py) with the -n/--use-names option. Otherwise these "tags" will be ignored.

The other thing you're asking for is the thread-watcher.py file. Let's say you want to download every "wallpaper" thread from the /hr/ board then you'd have to run the following command:

python thread-watcher.py -b hr -q wallpaper -f queue.txt -n "HR-Wallpapers"

Right now there's one thread that contains "wallpaper" on /hr/ which is https://boards.4chan.org/hr/thread/4474136

So this script basically looks on the specified board (-b) for a search term (-q). This uses 4chan's built-in search. If the search returns something, it will look into the specified file (-f) and adds the found thread if it's not already there. It will also append the name/tag (-n) "HR-Wallpapers" to the end of the URL so that everything will be placed in the same folder. So in the end the file will contain this url: https://boards.4chan.org/hr/thread/4474136/HR-Wallpapers

i used the cmd for the autowatcher, but it did not work. i set the board and tag i wanted and ran it. but looking in the board later i found threads with that tag that were not put in the queue list

@Exceen
Copy link
Owner

Exceen commented Aug 17, 2022

could you please provide an example for this?

@Exceen Exceen closed this as not planned Won't fix, can't repro, duplicate, stale Sep 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants