Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the gem's dependecies #27

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .bundle/config

This file was deleted.

6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
pkg
vendor
/pkg
/vendor
/Gemfile.lock
/.bundle
15 changes: 15 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
language: ruby
cache: bundler
rvm:
- 1.9.3
- jruby
- 2.0.0
- 2.1
- 2.2
- ruby-head
gemfile:
- gemfiles/Gemfile.actionpack-3.2.x
- gemfiles/Gemfile.actionpack-4.0.x
- gemfiles/Gemfile.actionpack-4.1.x
- gemfiles/Gemfile.actionpack-4.2.x
- Gemfile
44 changes: 0 additions & 44 deletions Gemfile.lock

This file was deleted.

14 changes: 8 additions & 6 deletions README.markdown
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
Scheduler Daemon
================

[![Build Status](https://travis-ci.org/ssoroka/scheduler_daemon.svg?branch=master)](https://travis-ci.org/ssoroka/scheduler_daemon)

Rails 3+ compatible scheduler daemon (see branches for older versions).

Replaces cron/rake pattern of periodically running rake tasks
to perform maintenance tasks in Rails apps. Scheduler Daemon is made specifically for your Rails app,
Replaces cron/rake pattern of periodically running rake tasks
to perform maintenance tasks in Rails apps. Scheduler Daemon is made specifically for your Rails app,
and only loads the environment once, no matter how many tasks run.

What's so great about it? Well, I'm glad you asked!
Expand All @@ -29,7 +31,7 @@ As a gem, the old-fashioned way:
As a gem with bundler, add to your ./Gemfile:

gem 'scheduler_daemon'

I pretty much assume you chose this option below and prefix most commands with "bundle exec"

As a plugin (deprecated): (might be awkward to call the binary to start up the daemon...)
Expand All @@ -54,9 +56,9 @@ generate a new scheduled task:
rails generate scheduler_task MyTaskName

If you have problems with that, the template for new tasks is in the gem under:

lib/scheduler_daemon/rails/generators/scheduler_task/templates/scheduled_tasks/example_task.rb

you can always copy it and make modifications, or see "Manually create tasks" below.

Tasks support their own special DSL; commands are:
Expand Down Expand Up @@ -95,7 +97,7 @@ Here's an example task file.

class CleanUpTask < Scheduler::SchedulerTask
every '2m'

def run
do_something
log("I've done things")
Expand Down
75 changes: 4 additions & 71 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,73 +1,6 @@
require 'rubygems'
require 'rake'
require "bundler/gem_tasks"
require 'rspec/core/rake_task'

begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
gem.name = "scheduler_daemon"
gem.summary = %Q{Rails 3 compatible scheduler daemon. Replaces cron/rake pattern of periodically running rake tasks
to perform maintenance tasks in Rails apps. Scheduler Daemon is made specifically for your Rails app,
and only loads the environment once, no matter how many tasks run.
RSpec::Core::RakeTask.new(:spec)

What's so great about it? Well, I'm glad you asked!

- Only loads your Rails environment once on daemon start, not every time a task is run
- Allows you to easily deploy the scheduled tasks with your Rails app instead of depending on an
administrator to update crontab
- It doesn't use rake or cron!
- Gets you up and running with your own daemon in under 2 minutes
}
gem.version = File.read('VERSION').chomp
gem.description = 'a Rails 2.3, Rails 3, and Ruby compatible scheduler daemon. Replaces cron/rake pattern of periodically running rake tasks to perform maintenance tasks, only loading the environment ONCE.'
gem.email = "[email protected]"
gem.homepage = "http://github.com/ssoroka/scheduler_daemon"
gem.authors = ["Steven Soroka"]
gem.add_dependency('activesupport')
gem.add_dependency('eventmachine', '>= 0.12.8')
gem.add_dependency('daemons', '>= 1.0.10')
gem.add_dependency('rufus-scheduler', '~> 2.0.24')
gem.add_dependency('chronic', '>= 0.2.0')
gem.add_development_dependency('rspec', '~> 2.13.0')

gem.executables = ['scheduler_daemon']

everything_from_dirs = %w(bin lib spec)
gem.files = everything_from_dirs.map{|d| Dir["#{d}/**/*"] }.flatten
gem.files += Dir['*'] - (everything_from_dirs + %w(pkg vendor))
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
end

rescue LoadError
puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
end

# require 'spec/rake/spectask'
# Spec::Rake::SpecTask.new(:spec) do |spec|
# spec.libs << 'lib' << 'spec'
# spec.spec_files = FileList['spec/**/*_spec.rb']
# end
#
# Spec::Rake::SpecTask.new(:rcov) do |spec|
# spec.libs << 'lib' << 'spec'
# spec.pattern = 'spec/**/*_spec.rb'
# spec.rcov = true
# end
#
#
# task :default => :spec
#
# require 'rake/rdoctask'
# Rake::RDocTask.new do |rdoc|
# if File.exist?('VERSION.yml')
# config = YAML.load(File.read('VERSION.yml'))
# version = "#{config[:major]}.#{config[:minor]}.#{config[:patch]}"
# else
# version = ""
# end
#
# rdoc.rdoc_dir = 'rdoc'
# rdoc.title = "scheduler_daemon #{version}"
# rdoc.rdoc_files.include('README*')
# rdoc.rdoc_files.include('lib/**/*.rb')
# end
#
task :default => :spec
1 change: 0 additions & 1 deletion VERSION

This file was deleted.

4 changes: 4 additions & 0 deletions gemfiles/Gemfile.actionpack-3.2.x
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
source 'https://rubygems.org'

gemspec path: '../'
gem 'activesupport', '~> 3.2.0'
4 changes: 4 additions & 0 deletions gemfiles/Gemfile.actionpack-4.0.x
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
source 'https://rubygems.org'

gemspec path: '../'
gem 'activesupport', '~> 4.0.0'
4 changes: 4 additions & 0 deletions gemfiles/Gemfile.actionpack-4.1.x
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
source 'https://rubygems.org'

gemspec path: '../'
gem 'activesupport', '~> 4.1.0'
4 changes: 4 additions & 0 deletions gemfiles/Gemfile.actionpack-4.2.x
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
source 'https://rubygems.org'

gemspec path: '../'
gem 'activesupport', '~> 4.2.0'
89 changes: 22 additions & 67 deletions scheduler_daemon.gemspec
Original file line number Diff line number Diff line change
@@ -1,79 +1,34 @@
# Generated by jeweler
# DO NOT EDIT THIS FILE DIRECTLY
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
# -*- encoding: utf-8 -*-

Gem::Specification.new do |s|
s.name = "scheduler_daemon"
s.version = "1.1.5"
s.description = "a Rails 2.3, Rails 3, and Ruby compatible scheduler daemon. Replaces cron/rake pattern of periodically running rake tasks to perform maintenance tasks, only loading the environment ONCE."
s.summary = "Rails 3 compatible scheduler daemon. Replaces cron/rake pattern of periodically running rake tasks to perform maintenance tasks in Rails apps. Scheduler Daemon is made specifically for your Rails app, and only loads the environment once, no matter how many tasks run. What's so great about it? Well, I'm glad you asked! - Only loads your Rails environment once on daemon start, not every time a task is run - Allows you to easily deploy the scheduled tasks with your Rails app instead of depending on an administrator to update crontab - It doesn't use rake or cron! - Gets you up and running with your own daemon in under 2 minutes"
s.homepage = "http://github.com/ssoroka/scheduler_daemon"

s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Steven Soroka"]
s.date = "2014-02-25"
s.description = "a Rails 2.3, Rails 3, and Ruby compatible scheduler daemon. Replaces cron/rake pattern of periodically running rake tasks to perform maintenance tasks, only loading the environment ONCE."
s.email = "[email protected]"
s.executables = ["scheduler_daemon"]
s.extra_rdoc_files = [
"README.markdown"
]
s.files = [
"Gemfile",
"Gemfile.lock",
"MIT-LICENSE",
"README.markdown",
"Rakefile",
"VERSION",
"bin/scheduler_daemon",
"lib/loader/scheduler_loader.rb",
"lib/scheduler_daemon.rb",
"lib/scheduler_daemon/base.rb",
"lib/scheduler_daemon/command_line_args_to_hash.rb",
"lib/scheduler_daemon/exception_handler.rb",
"lib/scheduler_daemon/rails/generators/scheduler/USAGE",
"lib/scheduler_daemon/rails/generators/scheduler/scheduler_generator.rb",
"lib/scheduler_daemon/rails/generators/scheduler/templates/README",
"lib/scheduler_daemon/rails/generators/scheduler/templates/lib/scheduled_tasks/session_cleaner_task.rb",
"lib/scheduler_daemon/rails/generators/scheduler_task/scheduler_task_generator.rb",
"lib/scheduler_daemon/rails/generators/scheduler_task/templates/README",
"lib/scheduler_daemon/rails/generators/scheduler_task/templates/scheduled_tasks/example_task.rb",
"lib/scheduler_daemon/rails/railtie.rb",
"lib/scheduler_daemon/scheduler_task.rb",
"scheduler_daemon.gemspec",
"spec/command_line_args_to_hash_spec.rb",
"spec/scheduled_tasks/session_cleaner_task_spec.rb",
"spec/scheduler_spec.rb",
"spec/spec_helper.rb"
]
s.homepage = "http://github.com/ssoroka/scheduler_daemon"
s.require_paths = ["lib"]
s.rubygems_version = "1.8.23"
s.summary = "Rails 3 compatible scheduler daemon. Replaces cron/rake pattern of periodically running rake tasks to perform maintenance tasks in Rails apps. Scheduler Daemon is made specifically for your Rails app, and only loads the environment once, no matter how many tasks run. What's so great about it? Well, I'm glad you asked! - Only loads your Rails environment once on daemon start, not every time a task is run - Allows you to easily deploy the scheduled tasks with your Rails app instead of depending on an administrator to update crontab - It doesn't use rake or cron! - Gets you up and running with your own daemon in under 2 minutes"

if s.respond_to? :specification_version then
s.specification_version = 3
s.date = Time.now.strftime("%Y-%m-%d")
s.files = `git ls-files -z`.split("\x0")
s.executables = s.files.grep(%r{^bin/}) { |f| File.basename(f) }
s.require_paths = ["lib"]

if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
s.add_runtime_dependency(%q<activesupport>, [">= 0"])
s.add_runtime_dependency(%q<eventmachine>, [">= 0.12.8"])
s.add_runtime_dependency(%q<daemons>, [">= 1.0.10"])
s.add_runtime_dependency(%q<rufus-scheduler>, ["~> 2.0.24"])
s.add_runtime_dependency(%q<chronic>, [">= 0.2.0"])
s.add_development_dependency(%q<rspec>, ["~> 2.13.0"])
else
s.add_dependency(%q<activesupport>, [">= 0"])
s.add_dependency(%q<eventmachine>, [">= 0.12.8"])
s.add_dependency(%q<daemons>, [">= 1.0.10"])
s.add_dependency(%q<rufus-scheduler>, ["~> 2.0.24"])
s.add_dependency(%q<chronic>, [">= 0.2.0"])
s.add_dependency(%q<rspec>, ["~> 2.13.0"])
end
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0')
s.add_dependency("activesupport", ">= 0")
s.add_dependency("eventmachine", ">= 0.12.8")
s.add_dependency("daemons", ">= 1.0.10")
s.add_dependency("rufus-scheduler", "~> 2.0.24")
s.add_dependency("chronic", ">= 0.2.0")
s.add_development_dependency("rspec", "~> 2.13.0")
s.add_development_dependency("rake")
else
s.add_dependency(%q<activesupport>, [">= 0"])
s.add_dependency(%q<eventmachine>, [">= 0.12.8"])
s.add_dependency(%q<daemons>, [">= 1.0.10"])
s.add_dependency(%q<rufus-scheduler>, ["~> 2.0.24"])
s.add_dependency(%q<chronic>, [">= 0.2.0"])
s.add_dependency(%q<rspec>, ["~> 2.13.0"])
s.add_dependency("activesupport", [">= 0"])
s.add_dependency("eventmachine", [">= 0.12.8"])
s.add_dependency("daemons", [">= 1.0.10"])
s.add_dependency("rufus-scheduler", ["~> 2.0.24"])
s.add_dependency("chronic", [">= 0.2.0"])
s.add_dependency("rspec", ["~> 2.13.0"])
s.add_dependency("rake", [">= 0"])
end
end