mirror of
https://github.com/plashchynski/crono.git
synced 2026-03-20 16:44:18 +01:00
Add Cli class, fix gem loading issues
This commit is contained in:
@@ -2,8 +2,8 @@ PATH
|
||||
remote: .
|
||||
specs:
|
||||
periodicity (0.0.1)
|
||||
activejob
|
||||
activesupport
|
||||
activejob (~> 4.0)
|
||||
activesupport (~> 4.0)
|
||||
|
||||
GEM
|
||||
remote: https://rubygems.org/
|
||||
@@ -48,6 +48,6 @@ PLATFORMS
|
||||
DEPENDENCIES
|
||||
bundler (>= 1.0.0)
|
||||
periodicity!
|
||||
rake
|
||||
rake (~> 10.0)
|
||||
rspec (~> 3.0)
|
||||
timecop
|
||||
timecop (~> 0.7)
|
||||
|
||||
@@ -4,4 +4,7 @@ end
|
||||
require "active_support/all"
|
||||
require "periodicity/version.rb"
|
||||
require "periodicity/period.rb"
|
||||
require "periodicity/rails.rb"
|
||||
|
||||
require 'periodicity/extensions/active_job'
|
||||
require "periodicity/rails.rb" if defined?(::Rails::Engine)
|
||||
require "periodicity/cli.rb"
|
||||
|
||||
4
lib/periodicity/cli.rb
Normal file
4
lib/periodicity/cli.rb
Normal file
@@ -0,0 +1,4 @@
|
||||
module Periodicity
|
||||
class Cli
|
||||
end
|
||||
end
|
||||
@@ -1,7 +1,7 @@
|
||||
module Periodicity
|
||||
def self.hook_rails!
|
||||
ActiveSupport.on_load(:active_job) do
|
||||
extend Sidekiq::Extensions::ActiveJob
|
||||
extend Periodicity::Extensions::ActiveJob
|
||||
end
|
||||
end
|
||||
|
||||
@@ -9,5 +9,5 @@ module Periodicity
|
||||
initializer 'periodicity' do
|
||||
Periodicity.hook_rails!
|
||||
end
|
||||
end if defined?(::Rails)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -8,16 +8,17 @@ Gem::Specification.new do |s|
|
||||
s.email = ["plashchynski@gmail.com"]
|
||||
s.homepage = "https://github.com/plashchynski/periodicity"
|
||||
s.description = s.summary = "Job scheduler for Rails"
|
||||
s.license = "Apache-2.0"
|
||||
|
||||
s.required_rubygems_version = ">= 1.3.6"
|
||||
s.rubyforge_project = "periodicity"
|
||||
|
||||
s.add_runtime_dependency "activejob"
|
||||
s.add_runtime_dependency "activesupport"
|
||||
s.add_development_dependency "rake"
|
||||
s.add_runtime_dependency "activejob", "~> 4.0"
|
||||
s.add_runtime_dependency "activesupport", "~> 4.0"
|
||||
s.add_development_dependency "rake", "~> 10.0"
|
||||
s.add_development_dependency "bundler", ">= 1.0.0"
|
||||
s.add_development_dependency "rspec", "~> 3.0"
|
||||
s.add_development_dependency "timecop"
|
||||
s.add_development_dependency "timecop", "~> 0.7"
|
||||
|
||||
s.files = `git ls-files`.split("\n")
|
||||
s.executables = `git ls-files`.split("\n").map{|f| f =~ /^bin\/(.*)/ ? $1 : nil}.compact
|
||||
|
||||
Reference in New Issue
Block a user