sidekiq-job_alert 0.1.5 → 0.1.6

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
  SHA1:
3
- metadata.gz: 1ebae05bf920c412d640839f133b0fa028caf5c3
4
- data.tar.gz: d817838aa611f5a8a831ed81e1607152bf49ff2f
3
+ metadata.gz: 98291629350bcf4e112686d4a779de1a5872b5d4
4
+ data.tar.gz: e6ca619a26aa72497e7fa3a58770c536b24f8a15
5
5
  SHA512:
6
- metadata.gz: 8812b0957d32f160b5cfdecd37590ad6a24bd61f5a0b46d1b5d9c9e94c64f793672ebe28c61a56a07e8c7ba5ceaedd5ac6810da58bb2330ccda3a33db346fbc8
7
- data.tar.gz: 909758252d9e43e6a901145802036aad38f2c594a3293e2850155a8e96b55944bac2df7d5690c0f7df2fd7fa2c78900fc6f5319b80fd5c90d22e0c3114bf878f
6
+ metadata.gz: 7e99ba45ac580fcfa8590bc105082660f3f3395ef976289c753ae9ec49266c74c9def144582d2d6d384efc840215653ddf2307cba30d09ced4f2b46e02001e5b
7
+ data.tar.gz: '00190df96f940375587234ba99e7607b67dcd6ef2a3d3a8f714ad1883317cab904d6ffd845190763452c7ba08268a81c1eec69fddf62a3c5e0901ab5c75ef097'
data/.rubocop.yml ADDED
@@ -0,0 +1,20 @@
1
+ # The behavior of RuboCop can be controlled via the .rubocop.yml
2
+ # configuration file. It makes it possible to enable/disable
3
+ # certain cops (checks) and to alter their behavior if they accept
4
+ # any parameters. The file can be placed either in your home
5
+ # directory or in some project directory.
6
+ #
7
+ # RuboCop will start looking for the configuration file in the directory
8
+ # where the inspected file is and continue its way up to the root directory.
9
+ #
10
+ # See https://github.com/rubocop-hq/rubocop/blob/master/manual/configuration.md
11
+
12
+ # Allow both single and double quotation
13
+ Style/StringLiterals:
14
+ Enabled: false
15
+
16
+ Style/Documentation:
17
+ Enabled: false
18
+
19
+ Metrics/LineLength:
20
+ Max: 100
data/Gemfile CHANGED
@@ -1,6 +1,10 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source "https://rubygems.org"
2
4
 
3
- git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
5
+ git_source(:github) { |repo_name| "https://github.com/#{repo_name}" }
4
6
 
5
7
  # Specify your gem's dependencies in sidekiq-job_alert.gemspec
6
8
  gemspec
9
+
10
+ gem 'rubocop', '~> 0.75.0', require: false
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sidekiq-job_alert (0.1.5)
4
+ sidekiq-job_alert (0.1.6)
5
5
  sidekiq (~> 4.2.1)
6
6
  slack-notifier (~> 2.3.2)
7
7
  thor
@@ -9,12 +9,18 @@ PATH
9
9
  GEM
10
10
  remote: https://rubygems.org/
11
11
  specs:
12
+ ast (2.4.0)
12
13
  concurrent-ruby (1.1.5)
13
14
  connection_pool (2.2.2)
14
15
  diff-lcs (1.3)
16
+ jaro_winkler (1.5.3)
17
+ parallel (1.18.0)
18
+ parser (2.6.5.0)
19
+ ast (~> 2.4.0)
15
20
  rack (2.0.7)
16
21
  rack-protection (2.0.7)
17
22
  rack
23
+ rainbow (3.0.0)
18
24
  rake (10.5.0)
19
25
  redis (3.3.5)
20
26
  rspec (3.8.0)
@@ -30,6 +36,14 @@ GEM
30
36
  diff-lcs (>= 1.2.0, < 2.0)
31
37
  rspec-support (~> 3.8.0)
32
38
  rspec-support (3.8.2)
39
+ rubocop (0.75.0)
40
+ jaro_winkler (~> 1.5.1)
41
+ parallel (~> 1.10)
42
+ parser (>= 2.6)
43
+ rainbow (>= 2.2.2, < 4.0)
44
+ ruby-progressbar (~> 1.7)
45
+ unicode-display_width (>= 1.4.0, < 1.7)
46
+ ruby-progressbar (1.10.1)
33
47
  sidekiq (4.2.10)
34
48
  concurrent-ruby (~> 1.0)
35
49
  connection_pool (~> 2.2, >= 2.2.0)
@@ -37,6 +51,7 @@ GEM
37
51
  redis (~> 3.2, >= 3.2.1)
38
52
  slack-notifier (2.3.2)
39
53
  thor (0.20.3)
54
+ unicode-display_width (1.6.0)
40
55
 
41
56
  PLATFORMS
42
57
  ruby
@@ -45,6 +60,7 @@ DEPENDENCIES
45
60
  bundler (~> 1.16)
46
61
  rake (~> 10.0)
47
62
  rspec (~> 3.0)
63
+ rubocop (~> 0.75.0)
48
64
  sidekiq-job_alert!
49
65
 
50
66
  BUNDLED WITH
data/Rakefile CHANGED
@@ -1,6 +1,8 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require "bundler/gem_tasks"
2
4
  require "rspec/core/rake_task"
3
5
 
4
6
  RSpec::Core::RakeTask.new(:spec)
5
7
 
6
- task :default => :spec
8
+ task default: :spec
data/bin/console CHANGED
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
2
3
 
3
4
  require "bundler/setup"
4
5
  require "sidekiq/job_alert"
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
2
3
 
3
4
  require "sidekiq/job_alert"
4
5
 
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'thor'
2
4
  require 'sidekiq/job_alert'
3
5
 
@@ -7,7 +7,7 @@ module Sidekiq
7
7
  module JobAlert
8
8
  class Notifier
9
9
  def initialize(config)
10
- @slack_config ||= YAML::load_file(config)
10
+ @slack_config = YAML.load_file(config)
11
11
  @message = ''
12
12
  end
13
13
 
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Sidekiq
2
4
  module JobAlert
3
- VERSION = "0.1.5"
5
+ VERSION = "0.1.6"
4
6
  end
5
7
  end
@@ -1,5 +1,6 @@
1
+ # frozen_string_literal: true
1
2
 
2
- lib = File.expand_path("../lib", __FILE__)
3
+ lib = File.expand_path('lib', __dir__)
3
4
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
5
  require "sidekiq/job_alert/version"
5
6
 
@@ -9,15 +10,17 @@ Gem::Specification.new do |spec|
9
10
  spec.authors = ["feng.zhang"]
10
11
  spec.email = ["cst.feng@gmail.com"]
11
12
 
12
- spec.summary = %q{Send alert to Slack if too many waiting jobs or dead jobs}
13
- spec.description = %q{Send alert to Slack if too many waiting jobs or dead jobs}
13
+ spec.summary = 'Send alert to Slack if too many waiting jobs or dead jobs'
14
+ spec.description = 'Send alert to Slack if too many waiting jobs or dead jobs'
14
15
  spec.homepage = "https://github.com/arthurbryant/sidekiq-job_alert"
15
16
  spec.license = "MIT"
16
17
 
17
18
  # Specify which files should be added to the gem when it is released.
18
19
  # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
19
- spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
20
- `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
20
+ spec.files = Dir.chdir(File.expand_path(__dir__)) do
21
+ `git ls-files -z`.split("\x0").reject do |f|
22
+ f.match(%r{^(test|spec|features)/})
23
+ end
21
24
  end
22
25
  spec.bindir = "exe"
23
26
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq-job_alert
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - feng.zhang
@@ -104,6 +104,7 @@ extra_rdoc_files: []
104
104
  files:
105
105
  - ".gitignore"
106
106
  - ".rspec"
107
+ - ".rubocop.yml"
107
108
  - ".travis.yml"
108
109
  - CODE_OF_CONDUCT.md
109
110
  - Gemfile