dmm-crawler 0.2.6 → 0.2.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/README.md +25 -2
- data/lib/dmm-crawler/attributes.rb +5 -3
- data/lib/dmm-crawler/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 18b44134e22ed066117f64c8de14c3d8b460da0cc107737384fc63e619ca1576
|
4
|
+
data.tar.gz: ea76fffeed4b683705556b5c8506bfd5d0b1d728b090cd0bf48d62c3167ffb14
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1302f022bf9769fe4b25fe17a4ae0bdef2a19c715ea57e59893c4e78778a7192dc36fd7feb9e298ca5c98f7efd612762e5fb78f9a2ac4a8487ae425ce5fe6722
|
7
|
+
data.tar.gz: a1ad3ce32a7558e602a9a4be85fc2cdcb7ce781873f32465d64ea7da82b9df376cb74fb6361f9a0f08b6c40ed653d994a3f08abd0a5b832a13371aab67a963c3
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -16,7 +16,7 @@ gem 'dmm-crawler'
|
|
16
16
|
|
17
17
|
## Usage
|
18
18
|
|
19
|
-
|
19
|
+
### DMM.R18 Doujin Ranking
|
20
20
|
|
21
21
|
```ruby
|
22
22
|
require 'dmm-crawler'
|
@@ -44,10 +44,33 @@ client.rankings(term: '24', submedia: 'cg')
|
|
44
44
|
|
45
45
|
For example, Above command will show the doujin cg 24's ranking.
|
46
46
|
|
47
|
-
|
47
|
+
#### Available arguments
|
48
|
+
|
48
49
|
- Arguments for the term is able to use `all, comic, cg, game, voice`.
|
49
50
|
- Arguments for the submedia is able to use `24, weekly, monthly, total`.
|
50
51
|
|
52
|
+
### From an art's URL
|
53
|
+
|
54
|
+
```
|
55
|
+
require 'dmm-crawler'
|
56
|
+
|
57
|
+
include DMMCrawler
|
58
|
+
|
59
|
+
client = Client.new do |agent|
|
60
|
+
agent.ignore_bad_chunking = false
|
61
|
+
end
|
62
|
+
|
63
|
+
URL = 'https://www.dmm.co.jp/dc/doujin/-/detail/=/cid=d_087090'
|
64
|
+
|
65
|
+
client.get_attributes(URL)
|
66
|
+
# =>
|
67
|
+
# [
|
68
|
+
# ...
|
69
|
+
# ]
|
70
|
+
```
|
71
|
+
|
72
|
+
It returns art information by Array.
|
73
|
+
|
51
74
|
## Contributing
|
52
75
|
|
53
76
|
1. Fork it
|
@@ -61,9 +61,11 @@ module DMMCrawler
|
|
61
61
|
end
|
62
62
|
|
63
63
|
def price
|
64
|
-
|
65
|
-
|
66
|
-
|
64
|
+
Integer(
|
65
|
+
@page
|
66
|
+
.search('.m-priceList .priceList__sub.priceList__sub--big')
|
67
|
+
.text.strip.delete('円,')
|
68
|
+
)
|
67
69
|
end
|
68
70
|
|
69
71
|
def author
|
data/lib/dmm-crawler/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dmm-crawler
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Satoshi Ohmori
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mechanize
|