qiita_trend 0.2.9 → 0.3.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8557280f29f19f12c0b2f4231de327a2434fde8d00a851d2c32b4e1e6e3f654d
4
- data.tar.gz: 673102ee7ada1e88546afa02d69d0b3bf74d905d0cdeef8f489e0f9b0e5d8fc7
3
+ metadata.gz: 2dd970e1dd4d53b1f9f1f6fadc506f1ba55d256f4702c7a288099aacbb78ee59
4
+ data.tar.gz: b44e084aeaf9ca6e8ab0f4d0c46a9822f78a46b866d535c5786337d8cfd40527
5
5
  SHA512:
6
- metadata.gz: 61a8dcc3e28f98f7c4d4c1379f902a9a62c004e692b8a7f77bc0e3ff55cdd932d06276059a87650a7a4c0920e7faa78ab836c06bcfc215b523eb29a9e02732b8
7
- data.tar.gz: fbcbb3787ffe7b8394fb2651507255d652f358b36493abc2d6c6bf0e20a1ba8d30c993b3f656ffc8e2495da75a0906e20d41f63e08b468645aa09744c35934da
6
+ metadata.gz: b068f52643d97848e004045ba9584765816e6a4dc426ce5e65efbb0106d32853ec9798992a0ee839650466c4b2a796e438ef9174320e822fd9d8adc2e7c400a6
7
+ data.tar.gz: c975ac069b39ce24004b7b963c63d55166f2d06a056005a4f05bd4b820ad33b2c960a664f47b07df54557439f2d4f0c0c143d201aee37ad4028162f425df7246
data/.circleci/config.yml CHANGED
@@ -6,54 +6,59 @@ version: 2
6
6
  jobs:
7
7
  build:
8
8
  docker:
9
- # specify the version you desire here
10
- - image: circleci/ruby:2.6.0-node-browsers
9
+ - image: circleci/ruby:2.6.0
11
10
  environment:
12
- BUNDLER_VERSION: 2.0.1
13
-
14
- # Specify service dependencies here if necessary
15
- # CircleCI maintains a library of pre-built images
16
- # documented at https://circleci.com/docs/2.0/circleci-images/
17
- # - image: circleci/postgres:9.4
11
+ BUNDLE_PATH: vendor/bundle
18
12
 
19
13
  working_directory: ~/repo
20
14
 
21
15
  steps:
22
16
  - checkout
23
- # Download and cache dependencies
17
+
18
+ # Install Bundler
19
+ # ref:https://discuss.circleci.com/t/using-bundler-2-0-during-ci-fails/27411
20
+ - run:
21
+ name: Install Bundler
22
+ command: |
23
+ echo 'export BUNDLER_VERSION=$(cat Gemfile.lock | tail -1 | tr -d " ")' >> $BASH_ENV
24
+ source $BASH_ENV
25
+ gem install bundler
26
+
27
+ # Which version of bundler?
28
+ - run:
29
+ name: Which bundler?
30
+ command: bundle -v
31
+
32
+ # Restore bundle cache
33
+ # Read about caching dependencies: https://circleci.com/docs/2.0/caching/
24
34
  - restore_cache:
25
35
  keys:
26
36
  - v1-dependencies-{{ checksum "Gemfile.lock" }}
27
37
  # fallback to using the latest cache if no exact match is found
28
38
  - v1-dependencies-
29
- # install Bundler!
30
- # ref:https://discuss.circleci.com/t/using-bundler-2-0-during-ci-fails/27411
31
- - run:
32
- name: install bundler
33
- command: |
34
- sudo gem update --system
35
- sudo gem uninstall bundler
36
- sudo rm /usr/local/bin/bundle
37
- sudo rm /usr/local/bin/bundler
38
- sudo gem install bundler
39
- # install gem!
39
+
40
+ # Install gem
40
41
  - run:
41
- name: install gem
42
+ name: Install gem
42
43
  command: |
43
44
  # jobs=4は並列処理をして高速化するための設定(4つのjobで実行するって意味)
44
45
  bundle check --path=vendor/bundle || bundle install --path=vendor/bundle --jobs=4 --retry=3
46
+
47
+ # Store bundle cache for Ruby dependencies
45
48
  - save_cache:
46
49
  paths:
47
50
  - ./vendor/bundle
48
51
  key: v1-dependencies-{{ checksum "Gemfile.lock" }}
49
- # run rubocop!
52
+
53
+ # Run RuboCop
50
54
  - run:
51
- name: run rubocop
55
+ name: Run RuboCop
52
56
  command: |
53
57
  bundle exec rubocop
54
- # run tests!
58
+
59
+ # Run tests
55
60
  - run:
56
- name: run tests
61
+ name: Run tests
57
62
  command: |
58
63
  TEST_FILES="$(circleci tests glob "spec/**/*_spec.rb" | circleci tests split --split-by=timings)"
59
64
  bundle exec rspec \
@@ -62,12 +67,14 @@ jobs:
62
67
  --out test_results/rspec.xml \
63
68
  --format progress \
64
69
  $TEST_FILES
65
- # create document
70
+
71
+ # Create document
66
72
  - run:
67
- name: create document
73
+ name: Create document
68
74
  command: |
69
75
  bundle exec yard
70
- # collect reports
76
+
77
+ # Collect Reports
71
78
  - store_test_results:
72
79
  path: test_results
73
80
  - store_artifacts:
@@ -82,14 +89,64 @@ jobs:
82
89
  # ドキュメントの結果をyard-resultsディレクトリに吐き出す
83
90
  path: ./doc
84
91
  destination: yard-results
85
- # deploy RubyGems
86
- - deploy:
92
+
93
+ deploy:
94
+ docker:
95
+ - image: circleci/ruby:2.6.0
96
+
97
+ steps:
98
+ - checkout
99
+
100
+ # Install Bundler
101
+ # ref:https://discuss.circleci.com/t/using-bundler-2-0-during-ci-fails/27411
102
+ - run:
103
+ name: install Bundler
104
+ command: |
105
+ echo 'export BUNDLER_VERSION=$(cat Gemfile.lock | tail -1 | tr -d " ")' >> $BASH_ENV
106
+ source $BASH_ENV
107
+ gem install bundler
108
+
109
+ # Which version of bundler?
110
+ - run:
111
+ name: Which bundler?
112
+ command: bundle -v
113
+
114
+ # Restore bundle cache
115
+ # Read about caching dependencies: https://circleci.com/docs/2.0/caching/
116
+ - restore_cache:
117
+ keys:
118
+ - v1-dependencies-{{ checksum "Gemfile.lock" }}
119
+ - v1-dependencies-
120
+
121
+ # Install gem
122
+ - run:
123
+ name: Install gem
124
+ command: bundle check --path vendor/bundle || bundle install
125
+
126
+ # Store bundle cache for Ruby dependencies
127
+ - save_cache:
128
+ key: v1-dependencies-{{ checksum "Gemfile.lock" }}
129
+ paths:
130
+ - vendor/bundle
131
+
132
+ # Deploy RubyGems
133
+ - run:
134
+ name: Deploy RubyGems
87
135
  command: |
88
- if [ "${CIRCLE_BRANCH}" == "master" ]; then
89
- mkdir ~/.gem
90
- curl -u dodonki1223:$RUBYGEMS_PASSWORD https://rubygems.org/api/v1/api_key.yaml > ~/.gem/credentials; chmod 0600 ~/.gem/credentials
91
- git config user.name dodonki1223
92
- git config user.email $RUBYGEMS_EMAIL
93
- bundle exec rake build
94
- bundle exec rake release
95
- fi
136
+ curl -u dodonki1223:$RUBYGEMS_PASSWORD https://rubygems.org/api/v1/api_key.yaml > ~/.gem/credentials; chmod 0600 ~/.gem/credentials
137
+ git config user.name dodonki1223
138
+ git config user.email $RUBYGEMS_EMAIL
139
+ bundle exec rake build
140
+ bundle exec rake release
141
+
142
+ workflows:
143
+ version: 2
144
+ build-and-deploy:
145
+ jobs:
146
+ - build
147
+ - deploy:
148
+ requires:
149
+ - build
150
+ filters:
151
+ branches:
152
+ only: master # masterブランチの時だけDeployJobを実行するようにする
data/.gitignore CHANGED
@@ -12,4 +12,5 @@
12
12
  .rspec_status
13
13
 
14
14
  /cache/
15
- /spec/vcr/
15
+ /spec/vcr/
16
+ /vendor/
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- qiita_trend (0.2.9)
4
+ qiita_trend (0.3.0)
5
5
  mechanize
6
6
  nokogiri (~> 1.9)
7
7
 
@@ -39,7 +39,7 @@ GEM
39
39
  net-http-digest_auth (1.4.1)
40
40
  net-http-persistent (3.1.0)
41
41
  connection_pool (~> 2.2)
42
- nokogiri (1.10.3)
42
+ nokogiri (1.10.4)
43
43
  mini_portile2 (~> 2.4.0)
44
44
  ntlm-http (0.1.1)
45
45
  parallel (1.17.0)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module QiitaTrend
4
- VERSION = '0.2.9'
4
+ VERSION = '0.3.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: qiita_trend
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.9
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - dodonki1223
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-08-09 00:00:00.000000000 Z
11
+ date: 2019-08-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mechanize
@@ -229,7 +229,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
229
229
  - !ruby/object:Gem::Version
230
230
  version: '0'
231
231
  requirements: []
232
- rubygems_version: 3.0.4
232
+ rubygems_version: 3.0.1
233
233
  signing_key:
234
234
  specification_version: 4
235
235
  summary: Easy to get trend for Qiita in 10 seconds