obbistrano 1.1.70 → 1.1.71
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.
- data/lib/obbistrano_tasks.rb +50 -37
- data/obbistrano.gemspec +1 -1
- metadata +7 -16
data/lib/obbistrano_tasks.rb
CHANGED
|
@@ -266,6 +266,7 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
|
266
266
|
run "rm -f /etc/apache2/sites-enabled/#{user_to_config}.conf; ln -s /home/#{user_to_config}/#{deploy_to}/app/platform/apache.conf /etc/apache2/sites-enabled/#{user_to_config}.conf"
|
|
267
267
|
end
|
|
268
268
|
user_cron_tasks = capture("cat #{deploy_to}/app/platform/crontab")
|
|
269
|
+
logger.info "Writing User Cron File"
|
|
269
270
|
write_crontab(user_cron_tasks)
|
|
270
271
|
rescue
|
|
271
272
|
|
|
@@ -513,48 +514,60 @@ Capistrano::Configuration.instance(:must_exist).load do
|
|
|
513
514
|
|
|
514
515
|
namespace :bundle do
|
|
515
516
|
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
bundle_name = if bundle_name.index("/") then bundle_name[0..bundle_name.index("/")-1] else bundle_name end
|
|
524
|
-
next if bundle_name.empty?
|
|
525
|
-
files = recursive_file_list(bundle_directory, ".css")
|
|
526
|
-
next if files.empty? || bundle_name == 'dev'
|
|
527
|
-
bundle = ''
|
|
528
|
-
files.each do |file_path|
|
|
529
|
-
bundle << File.read(file_path) << "\n"
|
|
530
|
-
end
|
|
531
|
-
target = "#{build_to}/public/stylesheets/build/#{bundle_name}_combined.css"
|
|
532
|
-
File.open(target, 'w') { |f| f.write(bundle) }
|
|
517
|
+
task :css, :roles => [:web] do
|
|
518
|
+
paths = get_top_level_directories("#{build_to}/public/stylesheets")
|
|
519
|
+
paths = paths | get_top_level_directories("#{build_to}/plugins/cms/resources/public/stylesheets") if defined? "#{cms}"
|
|
520
|
+
paths << "#{build_to}/public/stylesheets/"
|
|
521
|
+
if defined? "#{plugins}"
|
|
522
|
+
plugins.each do |plugin|
|
|
523
|
+
paths << "#{build_to}/plugins/#{plugin}/resources/public/stylesheets"
|
|
533
524
|
end
|
|
534
|
-
upload "#{build_to}/public/stylesheets/build", "#{deploy_to}/public/stylesheets/", :via => :scp, :recursive=>true
|
|
535
525
|
end
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
files = recursive_file_list(bundle_directory, ".js")
|
|
547
|
-
next if files.empty? || bundle_name == 'dev'
|
|
548
|
-
bundle = ''
|
|
549
|
-
files.each do |file_path|
|
|
550
|
-
bundle << File.read(file_path) << "\n"
|
|
551
|
-
end
|
|
552
|
-
target = "#{build_to}/public/javascripts/build/#{bundle_name}_combined.js"
|
|
553
|
-
File.open(target, 'w') { |f| f.write(bundle) }
|
|
526
|
+
Dir.mkdir("#{build_to}/public/stylesheets/build") rescue ""
|
|
527
|
+
paths.each do |bundle_directory|
|
|
528
|
+
bundle_name = bundle_directory.gsub(/(cms)|(\/plugins)|(resources)|(public)|(stylesheets)|(\/)/i, "")
|
|
529
|
+
bundle_name = if(bundle_name.index(".") == 0) then bundle_name[1..bundle_name.length] else bundle_name end
|
|
530
|
+
next if bundle_name.empty?
|
|
531
|
+
files = recursive_file_list(bundle_directory, ".css")
|
|
532
|
+
next if files.empty? || bundle_name == 'dev'
|
|
533
|
+
bundle = ''
|
|
534
|
+
files.each do |file_path|
|
|
535
|
+
bundle << File.read(file_path) << "\n"
|
|
554
536
|
end
|
|
555
|
-
|
|
537
|
+
target = "#{build_to}/public/stylesheets/build/#{bundle_name}_combined.css"
|
|
538
|
+
File.open(target, 'w') { |f| f.write(bundle) }
|
|
539
|
+
end
|
|
540
|
+
upload "#{build_to}/public/stylesheets/build", "#{deploy_to}/public/stylesheets/", :via => :scp, :recursive=>true
|
|
541
|
+
end
|
|
556
542
|
|
|
543
|
+
task :js , :roles => [:web] do
|
|
544
|
+
paths = get_top_level_directories("#{build_to}/public/javascripts")
|
|
545
|
+
paths = paths | get_top_level_directories("#{build_to}/plugins/cms/resources/public/javascripts") if defined? "#{cms}"
|
|
546
|
+
paths << "#{build_to}/public/javascripts/"
|
|
547
|
+
if defined? "#{plugins}"
|
|
548
|
+
plugins.each do |plugin|
|
|
549
|
+
paths << "#{build_to}/plugins/#{plugin}/resources/public/javascripts"
|
|
550
|
+
end
|
|
557
551
|
end
|
|
552
|
+
Dir.mkdir("#{build_to}/public/javascripts/build") rescue ""
|
|
553
|
+
paths.each do |bundle_directory|
|
|
554
|
+
puts bundle_directory
|
|
555
|
+
bundle_name = bundle_directory.gsub(/(cms)|(\/plugins)|(resources)|(public)|(javascripts)|(\/)/i, "")
|
|
556
|
+
bundle_name = if(bundle_name.index(".") == 0) then bundle_name[1..bundle_name.length] else bundle_name end
|
|
557
|
+
next if bundle_name.empty?
|
|
558
|
+
files = recursive_file_list(bundle_directory, ".js")
|
|
559
|
+
next if files.empty? || bundle_name == 'dev'
|
|
560
|
+
bundle = ''
|
|
561
|
+
files.each do |file_path|
|
|
562
|
+
bundle << File.read(file_path) << "\n"
|
|
563
|
+
end
|
|
564
|
+
target = "#{build_to}/public/javascripts/build/#{bundle_name}_combined.js"
|
|
565
|
+
File.open(target, 'w') { |f| f.write(bundle) }
|
|
566
|
+
end
|
|
567
|
+
upload "#{build_to}/public/javascripts/build", "#{deploy_to}/public/javascripts/", :via => :scp, :recursive=>true
|
|
568
|
+
|
|
569
|
+
end
|
|
570
|
+
|
|
558
571
|
|
|
559
572
|
require 'find'
|
|
560
573
|
def recursive_file_list(basedir, ext)
|
data/obbistrano.gemspec
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Gem::Specification.new do |s|
|
|
4
4
|
s.name = %q{obbistrano}
|
|
5
|
-
s.version = "1.1.
|
|
5
|
+
s.version = "1.1.71"
|
|
6
6
|
s.authors = ["Ross Riley", "One Black Bear"]
|
|
7
7
|
s.date = Time.now
|
|
8
8
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
metadata
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: obbistrano
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
|
|
5
|
-
prerelease:
|
|
4
|
+
prerelease: false
|
|
6
5
|
segments:
|
|
7
6
|
- 1
|
|
8
7
|
- 1
|
|
9
|
-
-
|
|
10
|
-
version: 1.1.
|
|
8
|
+
- 71
|
|
9
|
+
version: 1.1.71
|
|
11
10
|
platform: ruby
|
|
12
11
|
authors:
|
|
13
12
|
- Ross Riley
|
|
@@ -16,17 +15,16 @@ autorequire:
|
|
|
16
15
|
bindir: bin
|
|
17
16
|
cert_chain: []
|
|
18
17
|
|
|
19
|
-
date:
|
|
18
|
+
date: 2012-02-22 00:00:00 +00:00
|
|
19
|
+
default_executable:
|
|
20
20
|
dependencies:
|
|
21
21
|
- !ruby/object:Gem::Dependency
|
|
22
22
|
name: capistrano
|
|
23
23
|
prerelease: false
|
|
24
24
|
requirement: &id001 !ruby/object:Gem::Requirement
|
|
25
|
-
none: false
|
|
26
25
|
requirements:
|
|
27
26
|
- - ">="
|
|
28
27
|
- !ruby/object:Gem::Version
|
|
29
|
-
hash: 9
|
|
30
28
|
segments:
|
|
31
29
|
- 2
|
|
32
30
|
- 5
|
|
@@ -37,11 +35,9 @@ dependencies:
|
|
|
37
35
|
name: activeresource
|
|
38
36
|
prerelease: false
|
|
39
37
|
requirement: &id002 !ruby/object:Gem::Requirement
|
|
40
|
-
none: false
|
|
41
38
|
requirements:
|
|
42
39
|
- - ">="
|
|
43
40
|
- !ruby/object:Gem::Version
|
|
44
|
-
hash: 7
|
|
45
41
|
segments:
|
|
46
42
|
- 2
|
|
47
43
|
version: "2"
|
|
@@ -51,11 +47,9 @@ dependencies:
|
|
|
51
47
|
name: httparty
|
|
52
48
|
prerelease: false
|
|
53
49
|
requirement: &id003 !ruby/object:Gem::Requirement
|
|
54
|
-
none: false
|
|
55
50
|
requirements:
|
|
56
51
|
- - ">="
|
|
57
52
|
- !ruby/object:Gem::Version
|
|
58
|
-
hash: 9
|
|
59
53
|
segments:
|
|
60
54
|
- 0
|
|
61
55
|
- 4
|
|
@@ -79,6 +73,7 @@ files:
|
|
|
79
73
|
- lib/slicehost.rb
|
|
80
74
|
- lib/obbistrano_tasks.rb
|
|
81
75
|
- lib/templates/apache_vhost.erb
|
|
76
|
+
has_rdoc: true
|
|
82
77
|
homepage: http://github.com/oneblackbear/obbistrano
|
|
83
78
|
licenses: []
|
|
84
79
|
|
|
@@ -88,27 +83,23 @@ rdoc_options: []
|
|
|
88
83
|
require_paths:
|
|
89
84
|
- lib
|
|
90
85
|
required_ruby_version: !ruby/object:Gem::Requirement
|
|
91
|
-
none: false
|
|
92
86
|
requirements:
|
|
93
87
|
- - ">="
|
|
94
88
|
- !ruby/object:Gem::Version
|
|
95
|
-
hash: 3
|
|
96
89
|
segments:
|
|
97
90
|
- 0
|
|
98
91
|
version: "0"
|
|
99
92
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
100
|
-
none: false
|
|
101
93
|
requirements:
|
|
102
94
|
- - ">="
|
|
103
95
|
- !ruby/object:Gem::Version
|
|
104
|
-
hash: 3
|
|
105
96
|
segments:
|
|
106
97
|
- 0
|
|
107
98
|
version: "0"
|
|
108
99
|
requirements: []
|
|
109
100
|
|
|
110
101
|
rubyforge_project:
|
|
111
|
-
rubygems_version: 1.
|
|
102
|
+
rubygems_version: 1.3.6
|
|
112
103
|
signing_key:
|
|
113
104
|
specification_version: 2
|
|
114
105
|
summary: Adds extra namespaces to Capistrano to allow simple setup, deploys and maintenance.
|