apple_system_status 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.circleci/config.yml +5 -32
- data/CHANGELOG.md +19 -0
- data/README.md +2 -2
- data/lib/apple_system_status/crawler.rb +11 -2
- data/lib/apple_system_status/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: fdb02da837139b920ce149ed9c00eb36e1f29e4f947e62e6e44e6a51d91b2948
|
|
4
|
+
data.tar.gz: fe8fb64f2c99690e179b9cb2d7350869381f7ae8977a011a1c0f681117582486
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8ac5ff5d6188ab25320c79612223d51b9311bba5d256eb793183161ffb9efcfa04a981899f0234a8fe36869c06a258ba52b23f86ca75126dd12172049a55e51d
|
|
7
|
+
data.tar.gz: 866a50d5218a4e9d8f4aef626ddb1471b39aeae7dbb8de593c2dc746983da4ec0140dafc695915242ff30081e1e23b6085f05bfcf4935aaa641e21128d01c88c
|
data/.circleci/config.yml
CHANGED
|
@@ -21,14 +21,6 @@ default: &default
|
|
|
21
21
|
|
|
22
22
|
working_directory: ~/app
|
|
23
23
|
|
|
24
|
-
restore_repo_cache_option: &restore_repo_cache_option
|
|
25
|
-
key: v1-repo-{{ .Environment.CIRCLE_SHA1 }}
|
|
26
|
-
|
|
27
|
-
save_repo_cache_option: &save_repo_cache_option
|
|
28
|
-
key: v1-repo-{{ .Environment.CIRCLE_SHA1 }}
|
|
29
|
-
paths:
|
|
30
|
-
- ~/app
|
|
31
|
-
|
|
32
24
|
restore_bundle_cache_option: &restore_bundle_cache_option
|
|
33
25
|
keys:
|
|
34
26
|
- v1-bundle-{{ .Environment.CIRCLE_JOB }}-{{ epoch }}
|
|
@@ -41,8 +33,7 @@ save_bundle_cache_option: &save_bundle_cache_option
|
|
|
41
33
|
- ~/app/Gemfile.lock
|
|
42
34
|
|
|
43
35
|
rspec_steps: &rspec_steps
|
|
44
|
-
-
|
|
45
|
-
<<: *restore_repo_cache_option
|
|
36
|
+
- checkout
|
|
46
37
|
- restore_cache:
|
|
47
38
|
<<: *restore_bundle_cache_option
|
|
48
39
|
- run: ./.circleci/setup.sh
|
|
@@ -53,30 +44,12 @@ rspec_steps: &rspec_steps
|
|
|
53
44
|
- run: bundle exec codeclimate-test-reporter
|
|
54
45
|
|
|
55
46
|
build_jobs: &build_jobs
|
|
56
|
-
-
|
|
57
|
-
- ruby:2.
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
- ruby:2.3:
|
|
61
|
-
requires:
|
|
62
|
-
- checkout_code
|
|
63
|
-
- ruby:2.4:
|
|
64
|
-
requires:
|
|
65
|
-
- checkout_code
|
|
66
|
-
- ruby:2.5:
|
|
67
|
-
requires:
|
|
68
|
-
- checkout_code
|
|
47
|
+
- ruby:2.2
|
|
48
|
+
- ruby:2.3
|
|
49
|
+
- ruby:2.4
|
|
50
|
+
- ruby:2.5
|
|
69
51
|
|
|
70
52
|
jobs:
|
|
71
|
-
checkout_code:
|
|
72
|
-
<<: *default
|
|
73
|
-
|
|
74
|
-
steps:
|
|
75
|
-
- checkout
|
|
76
|
-
|
|
77
|
-
- save_cache:
|
|
78
|
-
<<: *save_repo_cache_option
|
|
79
|
-
|
|
80
53
|
ruby:2.2:
|
|
81
54
|
<<: *default
|
|
82
55
|
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
+
## [v1.0.0](https://github.com/sue445/apple_system_status/tree/v1.0.0) (2018-09-22)
|
|
4
|
+
[Full Changelog](https://github.com/sue445/apple_system_status/compare/v0.3.2...v1.0.0)
|
|
5
|
+
|
|
6
|
+
**Closed issues:**
|
|
7
|
+
|
|
8
|
+
- Use chrome headless instead of phantomjs [\#24](https://github.com/sue445/apple_system_status/issues/24)
|
|
9
|
+
|
|
10
|
+
**Merged pull requests:**
|
|
11
|
+
|
|
12
|
+
- Drop support ruby 2.1 [\#28](https://github.com/sue445/apple_system_status/pull/28) ([sue445](https://github.com/sue445))
|
|
13
|
+
- Remove activesupport from runtime dependency [\#27](https://github.com/sue445/apple_system_status/pull/27) ([sue445](https://github.com/sue445))
|
|
14
|
+
- Tweak spec [\#26](https://github.com/sue445/apple_system_status/pull/26) ([sue445](https://github.com/sue445))
|
|
15
|
+
- Migrate to Chrome Headless [\#25](https://github.com/sue445/apple_system_status/pull/25) ([sue445](https://github.com/sue445))
|
|
16
|
+
- Fix spec [\#23](https://github.com/sue445/apple_system_status/pull/23) ([sue445](https://github.com/sue445))
|
|
17
|
+
- Tweak gem group for development dependency [\#22](https://github.com/sue445/apple_system_status/pull/22) ([sue445](https://github.com/sue445))
|
|
18
|
+
- CI against ruby 2.5.0 [\#21](https://github.com/sue445/apple_system_status/pull/21) ([sue445](https://github.com/sue445))
|
|
19
|
+
- Fix failed spec [\#20](https://github.com/sue445/apple_system_status/pull/20) ([sue445](https://github.com/sue445))
|
|
20
|
+
- Fix failed spec [\#19](https://github.com/sue445/apple_system_status/pull/19) ([sue445](https://github.com/sue445))
|
|
21
|
+
|
|
3
22
|
## [v0.3.2](https://github.com/sue445/apple_system_status/tree/v0.3.2) (2017-08-26)
|
|
4
23
|
[Full Changelog](https://github.com/sue445/apple_system_status/compare/v0.3.1...v0.3.2)
|
|
5
24
|
|
data/README.md
CHANGED
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
[](https://coveralls.io/github/sue445/apple_system_status?branch=master)
|
|
10
10
|
|
|
11
11
|
## Requirements
|
|
12
|
-
* Ruby 2.
|
|
13
|
-
*
|
|
12
|
+
* Ruby 2.2+
|
|
13
|
+
* Headless CHrome
|
|
14
14
|
|
|
15
15
|
## Installation
|
|
16
16
|
|
|
@@ -5,16 +5,25 @@ module AppleSystemStatus
|
|
|
5
5
|
class Crawler
|
|
6
6
|
USER_AGENT = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.134 Safari/537.36"
|
|
7
7
|
|
|
8
|
+
DEFAULT_CHROME_OPTIONS_ARGS = %W(
|
|
9
|
+
headless
|
|
10
|
+
disable-gpu
|
|
11
|
+
window-size=1280,800
|
|
12
|
+
no-sandbox
|
|
13
|
+
user-agent=#{USER_AGENT}
|
|
14
|
+
).freeze
|
|
15
|
+
|
|
8
16
|
MAX_RETRY_COUNT = 5
|
|
9
17
|
|
|
10
|
-
|
|
18
|
+
# @param chrome_options_args [Array<String>]
|
|
19
|
+
def initialize(chrome_options_args: DEFAULT_CHROME_OPTIONS_ARGS)
|
|
11
20
|
Capybara.register_driver :chrome_headless do |app|
|
|
12
21
|
client = Selenium::WebDriver::Remote::Http::Default.new
|
|
13
22
|
client.read_timeout = 120
|
|
14
23
|
|
|
15
24
|
capabilities = Selenium::WebDriver::Remote::Capabilities.chrome(
|
|
16
25
|
chromeOptions: {
|
|
17
|
-
args:
|
|
26
|
+
args: chrome_options_args,
|
|
18
27
|
}
|
|
19
28
|
)
|
|
20
29
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: apple_system_status
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- sue445
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-09-
|
|
11
|
+
date: 2018-09-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: capybara
|