capsum 0.0.3 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/capsum.gemspec +12 -11
- data/depends.rb +2 -2
- data/lib/capsum/passenger.rb +10 -0
- data/lib/capsum/typical.rb +1 -0
- data/lib/capsum/whenever.rb +19 -0
- metadata +24 -8
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0
|
1
|
+
0.1.0
|
data/capsum.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{capsum}
|
8
|
-
s.version = "0.0
|
8
|
+
s.version = "0.1.0"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Sunteya"]
|
12
|
-
s.date = %q{2010-
|
12
|
+
s.date = %q{2010-05-26}
|
13
13
|
s.email = %q{Sunteya@gmail.com}
|
14
14
|
s.extra_rdoc_files = [
|
15
15
|
"README"
|
@@ -24,37 +24,38 @@ Gem::Specification.new do |s|
|
|
24
24
|
"lib/capsum.rb",
|
25
25
|
"lib/capsum/delayed_job.rb",
|
26
26
|
"lib/capsum/passenger.rb",
|
27
|
-
"lib/capsum/typical.rb"
|
27
|
+
"lib/capsum/typical.rb",
|
28
|
+
"lib/capsum/whenever.rb"
|
28
29
|
]
|
29
30
|
s.homepage = %q{http://github.com/sunteya/capsum}
|
30
31
|
s.rdoc_options = ["--charset=UTF-8"]
|
31
32
|
s.require_paths = ["lib"]
|
32
|
-
s.rubygems_version = %q{1.3.
|
33
|
+
s.rubygems_version = %q{1.3.7}
|
33
34
|
s.summary = %q{Collect gems and recipes related capistrano.}
|
34
35
|
|
35
36
|
if s.respond_to? :specification_version then
|
36
37
|
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
37
38
|
s.specification_version = 3
|
38
39
|
|
39
|
-
if Gem::Version.new(Gem::
|
40
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
40
41
|
s.add_runtime_dependency(%q<gem_loader>, [">= 0.2.0"])
|
41
|
-
s.add_runtime_dependency(%q<capistrano>, [">= 2.5.
|
42
|
+
s.add_runtime_dependency(%q<capistrano>, [">= 2.5.18"])
|
42
43
|
s.add_runtime_dependency(%q<capistrano_colors>, [">= 0.5.2"])
|
43
44
|
s.add_runtime_dependency(%q<capistrano-ext>, [">= 1.2.1"])
|
44
|
-
s.add_runtime_dependency(%q<capistrano-helpers>, [">= 0.3
|
45
|
+
s.add_runtime_dependency(%q<capistrano-helpers>, [">= 0.4.3"])
|
45
46
|
else
|
46
47
|
s.add_dependency(%q<gem_loader>, [">= 0.2.0"])
|
47
|
-
s.add_dependency(%q<capistrano>, [">= 2.5.
|
48
|
+
s.add_dependency(%q<capistrano>, [">= 2.5.18"])
|
48
49
|
s.add_dependency(%q<capistrano_colors>, [">= 0.5.2"])
|
49
50
|
s.add_dependency(%q<capistrano-ext>, [">= 1.2.1"])
|
50
|
-
s.add_dependency(%q<capistrano-helpers>, [">= 0.3
|
51
|
+
s.add_dependency(%q<capistrano-helpers>, [">= 0.4.3"])
|
51
52
|
end
|
52
53
|
else
|
53
54
|
s.add_dependency(%q<gem_loader>, [">= 0.2.0"])
|
54
|
-
s.add_dependency(%q<capistrano>, [">= 2.5.
|
55
|
+
s.add_dependency(%q<capistrano>, [">= 2.5.18"])
|
55
56
|
s.add_dependency(%q<capistrano_colors>, [">= 0.5.2"])
|
56
57
|
s.add_dependency(%q<capistrano-ext>, [">= 1.2.1"])
|
57
|
-
s.add_dependency(%q<capistrano-helpers>, [">= 0.3
|
58
|
+
s.add_dependency(%q<capistrano-helpers>, [">= 0.4.3"])
|
58
59
|
end
|
59
60
|
end
|
60
61
|
|
data/depends.rb
CHANGED
@@ -6,10 +6,10 @@ require "gem_loader"
|
|
6
6
|
GemLoader.setup do
|
7
7
|
|
8
8
|
scope :runtime do
|
9
|
-
gem "capistrano", ">= 2.5.
|
9
|
+
gem "capistrano", ">= 2.5.18"
|
10
10
|
gem "capistrano_colors", ">= 0.5.2", :require => nil
|
11
11
|
gem "capistrano-ext", ">= 1.2.1", :require => nil
|
12
|
-
gem "capistrano-helpers", ">= 0.3
|
12
|
+
gem "capistrano-helpers", ">= 0.4.3", :require => nil
|
13
13
|
# gem "cap-recipes", ">= 0.3.36", :require => nil
|
14
14
|
end
|
15
15
|
|
data/lib/capsum/passenger.rb
CHANGED
@@ -6,5 +6,15 @@ Capistrano::Configuration.instance(true).load do
|
|
6
6
|
task :restart, :roles => :app do
|
7
7
|
run "touch #{current_path}/tmp/restart.txt"
|
8
8
|
end
|
9
|
+
|
10
|
+
desc 'Start passenger'
|
11
|
+
task :start, :roles => :app do
|
12
|
+
# do nothing
|
13
|
+
end
|
14
|
+
|
15
|
+
desc 'Stop passenger'
|
16
|
+
task :stop, :roles => :app do
|
17
|
+
# do nothing
|
18
|
+
end
|
9
19
|
end
|
10
20
|
end
|
data/lib/capsum/typical.rb
CHANGED
@@ -5,6 +5,7 @@ require "capistrano-helpers/git"
|
|
5
5
|
|
6
6
|
require File.expand_path("../passenger.rb", __FILE__)
|
7
7
|
require File.expand_path("../delayed_job.rb", __FILE__)
|
8
|
+
require File.expand_path("../whenever.rb", __FILE__)
|
8
9
|
|
9
10
|
Capistrano::Configuration.instance(true).load do
|
10
11
|
set :rails_env, "production"
|
@@ -0,0 +1,19 @@
|
|
1
|
+
require File.expand_path("../../capsum.rb", __FILE__)
|
2
|
+
|
3
|
+
Capistrano::Configuration.instance(true).load do
|
4
|
+
namespace :whenever do
|
5
|
+
desc 'Update the crontab'
|
6
|
+
task :update, :roles => :db do
|
7
|
+
command = "if [ -e #{current_path}/config/schedule.rb ]; then cd #{current_path}; RAILS_ENV=#{rails_env} whenever --update-crontab #{application} --set primary=%s; fi"
|
8
|
+
run (command % true), :only => { :primary => true }
|
9
|
+
run (command % false), :except => { :primary => true }
|
10
|
+
end
|
11
|
+
|
12
|
+
desc 'Cleanup the crontab'
|
13
|
+
task :cleanup, :roles => :db do
|
14
|
+
run "if [ -e #{current_path}/config/schedule.rb ]; then cd #{current_path}; RAILS_ENV=#{rails_env} whenever --update-crontab #{application} --load-file /dev/null; fi"
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
after "deploy:symlink", "whenever:update"
|
19
|
+
end
|
metadata
CHANGED
@@ -1,12 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capsum
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
+
hash: 27
|
4
5
|
prerelease: false
|
5
6
|
segments:
|
6
7
|
- 0
|
8
|
+
- 1
|
7
9
|
- 0
|
8
|
-
|
9
|
-
version: 0.0.3
|
10
|
+
version: 0.1.0
|
10
11
|
platform: ruby
|
11
12
|
authors:
|
12
13
|
- Sunteya
|
@@ -14,16 +15,18 @@ autorequire:
|
|
14
15
|
bindir: bin
|
15
16
|
cert_chain: []
|
16
17
|
|
17
|
-
date: 2010-
|
18
|
+
date: 2010-05-26 00:00:00 +08:00
|
18
19
|
default_executable:
|
19
20
|
dependencies:
|
20
21
|
- !ruby/object:Gem::Dependency
|
21
22
|
name: gem_loader
|
22
23
|
prerelease: false
|
23
24
|
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
24
26
|
requirements:
|
25
27
|
- - ">="
|
26
28
|
- !ruby/object:Gem::Version
|
29
|
+
hash: 23
|
27
30
|
segments:
|
28
31
|
- 0
|
29
32
|
- 2
|
@@ -35,23 +38,27 @@ dependencies:
|
|
35
38
|
name: capistrano
|
36
39
|
prerelease: false
|
37
40
|
requirement: &id002 !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
38
42
|
requirements:
|
39
43
|
- - ">="
|
40
44
|
- !ruby/object:Gem::Version
|
45
|
+
hash: 63
|
41
46
|
segments:
|
42
47
|
- 2
|
43
48
|
- 5
|
44
|
-
-
|
45
|
-
version: 2.5.
|
49
|
+
- 18
|
50
|
+
version: 2.5.18
|
46
51
|
type: :runtime
|
47
52
|
version_requirements: *id002
|
48
53
|
- !ruby/object:Gem::Dependency
|
49
54
|
name: capistrano_colors
|
50
55
|
prerelease: false
|
51
56
|
requirement: &id003 !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
52
58
|
requirements:
|
53
59
|
- - ">="
|
54
60
|
- !ruby/object:Gem::Version
|
61
|
+
hash: 15
|
55
62
|
segments:
|
56
63
|
- 0
|
57
64
|
- 5
|
@@ -63,9 +70,11 @@ dependencies:
|
|
63
70
|
name: capistrano-ext
|
64
71
|
prerelease: false
|
65
72
|
requirement: &id004 !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
66
74
|
requirements:
|
67
75
|
- - ">="
|
68
76
|
- !ruby/object:Gem::Version
|
77
|
+
hash: 29
|
69
78
|
segments:
|
70
79
|
- 1
|
71
80
|
- 2
|
@@ -77,14 +86,16 @@ dependencies:
|
|
77
86
|
name: capistrano-helpers
|
78
87
|
prerelease: false
|
79
88
|
requirement: &id005 !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
80
90
|
requirements:
|
81
91
|
- - ">="
|
82
92
|
- !ruby/object:Gem::Version
|
93
|
+
hash: 9
|
83
94
|
segments:
|
84
95
|
- 0
|
96
|
+
- 4
|
85
97
|
- 3
|
86
|
-
|
87
|
-
version: 0.3.2
|
98
|
+
version: 0.4.3
|
88
99
|
type: :runtime
|
89
100
|
version_requirements: *id005
|
90
101
|
description:
|
@@ -106,6 +117,7 @@ files:
|
|
106
117
|
- lib/capsum/delayed_job.rb
|
107
118
|
- lib/capsum/passenger.rb
|
108
119
|
- lib/capsum/typical.rb
|
120
|
+
- lib/capsum/whenever.rb
|
109
121
|
has_rdoc: true
|
110
122
|
homepage: http://github.com/sunteya/capsum
|
111
123
|
licenses: []
|
@@ -116,23 +128,27 @@ rdoc_options:
|
|
116
128
|
require_paths:
|
117
129
|
- lib
|
118
130
|
required_ruby_version: !ruby/object:Gem::Requirement
|
131
|
+
none: false
|
119
132
|
requirements:
|
120
133
|
- - ">="
|
121
134
|
- !ruby/object:Gem::Version
|
135
|
+
hash: 3
|
122
136
|
segments:
|
123
137
|
- 0
|
124
138
|
version: "0"
|
125
139
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
140
|
+
none: false
|
126
141
|
requirements:
|
127
142
|
- - ">="
|
128
143
|
- !ruby/object:Gem::Version
|
144
|
+
hash: 3
|
129
145
|
segments:
|
130
146
|
- 0
|
131
147
|
version: "0"
|
132
148
|
requirements: []
|
133
149
|
|
134
150
|
rubyforge_project:
|
135
|
-
rubygems_version: 1.3.
|
151
|
+
rubygems_version: 1.3.7
|
136
152
|
signing_key:
|
137
153
|
specification_version: 3
|
138
154
|
summary: Collect gems and recipes related capistrano.
|