tempsms22 0.1.1 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/lib/tempsms22.rb +19 -17
- data.tar.gz.sig +0 -0
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 647d05cdd95f0ac88fe65ffadc591497aee3535bf6e228da7c314062a84544f1
|
4
|
+
data.tar.gz: ecb2a92740135501297a95325fde460f1502941771affef1d638a13adf63fb93
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fdf3c83e596493eafa279a87bde12956964b806dcc340694c7269597942b8f2cac1957777b1288e03690879bdfd1c235518c4f76ab7756b5fa817f204dac0c57
|
7
|
+
data.tar.gz: a665f80edb1f85ccd7c85a80c6d692fa177920dace5c8131988efeffe950b6332a154c34903111951ec9cb74f72725fad2f24081e090b101a25657fca8c00b0a
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/lib/tempsms22.rb
CHANGED
@@ -10,38 +10,40 @@ require 'ostruct'
|
|
10
10
|
|
11
11
|
class TempSMS22
|
12
12
|
|
13
|
-
|
13
|
+
attr_accessor :number
|
14
14
|
|
15
15
|
def initialize()
|
16
|
-
@url = 'https://receive-smss.com/'
|
17
|
-
get_smsnum()
|
18
|
-
end
|
19
16
|
|
20
|
-
|
17
|
+
@url = 'https://receive-smss.com/'
|
21
18
|
|
22
|
-
|
23
|
-
doc = Nokorexi.new(url).to_doc
|
24
|
-
table = doc.root.element('//table')
|
19
|
+
doc = Nokorexi.new(@url).to_doc
|
25
20
|
|
26
|
-
a =
|
27
|
-
x.
|
21
|
+
@a = doc.root.xpath('//a[@class="number-boxes1-item-button"]').map do |x|
|
22
|
+
x.attributes[:href][/\d+/]
|
28
23
|
end
|
29
24
|
|
30
|
-
|
25
|
+
end
|
31
26
|
|
27
|
+
def number()
|
28
|
+
@number = @a.sample
|
32
29
|
end
|
33
30
|
|
34
|
-
|
31
|
+
def numbers()
|
32
|
+
@a
|
33
|
+
end
|
35
34
|
|
36
|
-
def
|
35
|
+
def read(number=@number)
|
37
36
|
|
38
|
-
|
37
|
+
url = @url + 'sms/' + number + '/'
|
38
|
+
doc = Nokorexi.new(url).to_doc
|
39
|
+
table = doc.root.element('//table')
|
39
40
|
|
40
|
-
a =
|
41
|
-
x.
|
41
|
+
a = table.xpath('tbody/tr').map do |x|
|
42
|
+
x.xpath('td').map {|y| y.plaintext.strip }
|
42
43
|
end
|
43
44
|
|
44
|
-
|
45
|
+
a.map {|x| OpenStruct.new(%i(from text date).zip(x).to_h) }
|
46
|
+
|
45
47
|
end
|
46
48
|
|
47
49
|
end
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tempsms22
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -35,7 +35,7 @@ cert_chain:
|
|
35
35
|
ztXMxbpG+JjUz/fW9/Hgk0gp01NgNz0mgAvQ/T1kKnXzjCX/emLM/BELrgG+A50g
|
36
36
|
DiofcFRVJjgBmAXWh6f6wfj9
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date: 2022-05-
|
38
|
+
date: 2022-05-29 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: nokorexi
|
metadata.gz.sig
CHANGED
Binary file
|