nyaa-transmission 1.0.6 → 1.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/nyaa_search.rb +7 -4
- data/lib/providers.rb +6 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '087e8454525b4a7bb25d62b93e0cdb27dc456ce4a91c45a8249adeb1f644139e'
|
4
|
+
data.tar.gz: e6efcf67219d85dd9e4bafb7bcda6fbe0895d674cfed14b708df9914d983ec7b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2037ae0345dd2ee6ee7bd8e3532ef2c7a94807d8321538ebac18ac36c3192cd514663224f142dbb4c0b3fc6ffb98b1d3de55e1138344e61b32c512a27501ae0b
|
7
|
+
data.tar.gz: 1b3e9b98a6ae8fc713be6b96658999f61d82b5a6d9b5ceaba2bcd2dc6df6e57dc67c2080800406e26ee07e88a4c57f9e7e454b8390f8c738cdf4994f5d6fee2a
|
data/lib/nyaa_search.rb
CHANGED
@@ -20,21 +20,24 @@ module Nyaa::Category
|
|
20
20
|
end
|
21
21
|
|
22
22
|
class NyaaSearch
|
23
|
-
attr_accessor :filter, :category, :query, :page
|
23
|
+
attr_accessor :filter, :category, :query, :user, :page
|
24
24
|
|
25
25
|
def initialize(args={})
|
26
26
|
self.filter = args[:filter] || Nyaa::Filter::NoFilter
|
27
27
|
self.category = args[:category] || Nyaa::Category::AllCategories
|
28
28
|
self.query = args[:query] || ""
|
29
|
+
self.user = args[:user] || nil
|
29
30
|
self.page = args[:page] || 1
|
30
31
|
end
|
31
32
|
|
32
33
|
def querystring
|
33
|
-
|
34
|
+
form = {
|
34
35
|
"f" => self.filter,
|
35
36
|
"c" => self.category,
|
36
37
|
"q" => self.query,
|
37
|
-
"p" => self.page
|
38
|
-
|
38
|
+
"p" => self.page,
|
39
|
+
"u" => self.user,
|
40
|
+
}
|
41
|
+
URI.encode_www_form(form.compact)
|
39
42
|
end
|
40
43
|
end
|
data/lib/providers.rb
CHANGED
@@ -13,7 +13,8 @@ class HorribleSubs < Provider
|
|
13
13
|
search_criteria = NyaaSearch.new(
|
14
14
|
:filter => Nyaa::Filter::TrustedOnly,
|
15
15
|
:category => Nyaa::Category::Anime::EnglishTranslated,
|
16
|
-
:query => "
|
16
|
+
:query => "1080p -batch #{series}",
|
17
|
+
:user => "HorribleSubs",
|
17
18
|
:page => 1
|
18
19
|
)
|
19
20
|
|
@@ -27,7 +28,8 @@ class EraiRaws < Provider
|
|
27
28
|
search_criteria = NyaaSearch.new(
|
28
29
|
:filter => Nyaa::Filter::TrustedOnly,
|
29
30
|
:category => Nyaa::Category::Anime::EnglishTranslated,
|
30
|
-
:query => "
|
31
|
+
:query => "1080p -\"~\" #{series}",
|
32
|
+
:user => "Erai-raws",
|
31
33
|
:page => 1
|
32
34
|
)
|
33
35
|
|
@@ -41,7 +43,8 @@ class Blackjaxx < Provider
|
|
41
43
|
search_criteria = NyaaSearch.new(
|
42
44
|
:filter => Nyaa::Filter::NoFilter,
|
43
45
|
:category => Nyaa::Category::Anime::EnglishTranslated,
|
44
|
-
:query => "
|
46
|
+
:query => "1080p -batch #{series}",
|
47
|
+
:user => "Blackjaxx",
|
45
48
|
:page => 1
|
46
49
|
)
|
47
50
|
|