@@ -4,7 +4,7 @@ name: gelbooru-xpath
44# loosely based on danbooru
55
66# intended to capture filename as produced by gallery-dl (rule34_<id>_<hash>.<ext>)
7- sceneByFragment :
7+ sceneByFragment : &fragementscraper
88 action : scrapeXPath
99 queryURL : " {filename}"
1010 queryURLReplace :
@@ -28,31 +28,7 @@ sceneByFragment:
2828 - regex : ' ^(.*&id=)([0-9]+)_.*$' # capture numeric sequence at begining as ID
2929 with : " $1$2"
3030 scraper : postScraper
31- # intended to capture filename as produced by gallery-dl (rule34_<id>_<hash>.<ext>)
32- imageByFragment :
33- action : scrapeXPath
34- queryURL : " {filename}"
35- queryURLReplace :
36- filename :
37- - regex : " [^a-zA-Z\\ d\\ -._~]" # clean filename so that it can construct a valid url
38- with : " "
39- - regex : " ^gelbooru_(.*)" # map to domain by prefix
40- with : " https://gelbooru.com/index.php?page=post&s=view&id=$1"
41- - regex : " tbib_(.*)" # map to domain by prefix
42- with : " https://tbib.org/index.php?page=post&s=view&id=$1"
43- - regex : " ^rule34_(.*)" # map to domain by prefix
44- with : " https://rule34.xxx/index.php?page=post&s=view&id=$1"
45- - regex : " ^xbooru_(.*)" # map to domain by prefix
46- with : " https://xbooru.com/post/show/$1"
47- - regex : " ^/safebooru_(.*)" # map to domain by prefix
48- with : " https://safebooru.org/post/show/$1"
49- - regex : " ^/hypnohub_(.*)" # map to domain by prefix
50- with : " https://hypnohub.net/post/show/$1"
51- - regex : " ^yandere_(.*)" # map to domain by prefix
52- with : " https://yande.re/post/show/$1"
53- - regex : ' ^(.*[^0-9])([0-9]+)_.*$' # capture numeric sequence at begining as ID
54- with : " $1$2"
55- scraper : postScraper
31+ imageByFragment : *fragementscraper
5632
5733sceneByURL :
5834 - action : scrapeXPath
0 commit comments