bowline 0.9.3 → 0.9.4
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/Rakefile +2 -2
- data/VERSION +1 -1
- data/bin/bowline-gen +1 -1
- data/bowline.gemspec +7 -7
- data/lib/bowline/desktop/bridge.rb +2 -2
- data/lib/bowline/generators.rb +1 -1
- data/lib/bowline/initializer.rb +18 -23
- data/lib/bowline/tasks/app.rake +5 -9
- data/lib/bowline/version.rb +1 -1
- data/templates/Gemfile +1 -0
- data/templates/Rakefile +1 -1
- data/templates/config/boot.rb +2 -3
- data/templates/config/environment.rb +1 -1
- data/templates/script/build +1 -1
- data/templates/script/console +1 -1
- data/templates/script/generate +1 -1
- data/templates/script/init +1 -1
- data/templates/script/run +1 -1
- metadata +13 -6
data/Rakefile
CHANGED
@@ -8,7 +8,7 @@ begin
|
|
8
8
|
gemspec.description = "Ruby/JS GUI framework"
|
9
9
|
gemspec.authors = ["Alex MacCaw"]
|
10
10
|
gemspec.add_dependency('templater', '>= 0.3.2')
|
11
|
-
gemspec.add_dependency('activesupport', '>= 3.0.0.
|
11
|
+
gemspec.add_dependency('activesupport', '>= 3.0.0.beta4')
|
12
12
|
gemspec.add_dependency('rubyzip2', '>= 2.0.1')
|
13
13
|
gemspec.add_dependency('supermodel', '>= 0.1.3')
|
14
14
|
gemspec.add_dependency('bowline-bundler','>= 0.0.1')
|
@@ -29,7 +29,7 @@ rescue LoadError
|
|
29
29
|
end
|
30
30
|
|
31
31
|
task :write_version do
|
32
|
-
require File.join(File.dirname(__FILE__), *%w[lib bowline])
|
32
|
+
require File.expand_path(File.join(File.dirname(__FILE__), *%w[lib bowline]))
|
33
33
|
File.open('VERSION', 'w') {|f| f.write Bowline::Version::STRING }
|
34
34
|
end
|
35
35
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.9.
|
1
|
+
0.9.4
|
data/bin/bowline-gen
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
|
3
|
-
require File.join(File.dirname(__FILE__), *%w[.. lib bowline])
|
3
|
+
require File.join(File.expand_path(File.dirname(__FILE__)), *%w[.. lib bowline])
|
4
4
|
require 'bowline/generators'
|
5
5
|
|
6
6
|
Bowline::Generators.run_cli(Dir.pwd, 'bowline', Bowline::Version::STRING, ARGV)
|
data/bowline.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{bowline}
|
8
|
-
s.version = "0.9.
|
8
|
+
s.version = "0.9.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Alex MacCaw"]
|
12
|
-
s.date = %q{2010-
|
12
|
+
s.date = %q{2010-09-24}
|
13
13
|
s.default_executable = %q{bowline-gen}
|
14
14
|
s.description = %q{Ruby/JS GUI framework}
|
15
15
|
s.email = %q{alex@leadthinking.com}
|
@@ -130,7 +130,7 @@ Gem::Specification.new do |s|
|
|
130
130
|
}
|
131
131
|
s.rdoc_options = ["--charset=UTF-8"]
|
132
132
|
s.require_paths = ["lib"]
|
133
|
-
s.rubygems_version = %q{1.3.
|
133
|
+
s.rubygems_version = %q{1.3.7}
|
134
134
|
s.summary = %q{Bowline GUI framework}
|
135
135
|
s.test_files = [
|
136
136
|
"examples/tweet.rb",
|
@@ -142,22 +142,22 @@ Gem::Specification.new do |s|
|
|
142
142
|
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
143
143
|
s.specification_version = 3
|
144
144
|
|
145
|
-
if Gem::Version.new(Gem::
|
145
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
146
146
|
s.add_runtime_dependency(%q<templater>, [">= 0.3.2"])
|
147
|
-
s.add_runtime_dependency(%q<activesupport>, [">= 3.0.0.
|
147
|
+
s.add_runtime_dependency(%q<activesupport>, [">= 3.0.0.beta4"])
|
148
148
|
s.add_runtime_dependency(%q<rubyzip2>, [">= 2.0.1"])
|
149
149
|
s.add_runtime_dependency(%q<supermodel>, [">= 0.1.3"])
|
150
150
|
s.add_runtime_dependency(%q<bowline-bundler>, [">= 0.0.1"])
|
151
151
|
else
|
152
152
|
s.add_dependency(%q<templater>, [">= 0.3.2"])
|
153
|
-
s.add_dependency(%q<activesupport>, [">= 3.0.0.
|
153
|
+
s.add_dependency(%q<activesupport>, [">= 3.0.0.beta4"])
|
154
154
|
s.add_dependency(%q<rubyzip2>, [">= 2.0.1"])
|
155
155
|
s.add_dependency(%q<supermodel>, [">= 0.1.3"])
|
156
156
|
s.add_dependency(%q<bowline-bundler>, [">= 0.0.1"])
|
157
157
|
end
|
158
158
|
else
|
159
159
|
s.add_dependency(%q<templater>, [">= 0.3.2"])
|
160
|
-
s.add_dependency(%q<activesupport>, [">= 3.0.0.
|
160
|
+
s.add_dependency(%q<activesupport>, [">= 3.0.0.beta4"])
|
161
161
|
s.add_dependency(%q<rubyzip2>, [">= 2.0.1"])
|
162
162
|
s.add_dependency(%q<supermodel>, [">= 0.1.3"])
|
163
163
|
s.add_dependency(%q<bowline-bundler>, [">= 0.0.1"])
|
@@ -67,6 +67,8 @@ module Bowline
|
|
67
67
|
end
|
68
68
|
|
69
69
|
def invoke
|
70
|
+
debug "JS invoking: #{klass}.#{method_name}(#{args.join(',')})"
|
71
|
+
|
70
72
|
if klass == "_window"
|
71
73
|
object = window
|
72
74
|
else
|
@@ -74,8 +76,6 @@ module Bowline
|
|
74
76
|
object = klass.constantize
|
75
77
|
end
|
76
78
|
|
77
|
-
debug "JS invoking: #{klass}.#{method_name}(#{args.join(',')})"
|
78
|
-
|
79
79
|
if object.respond_to?(:js_exposed?) &&
|
80
80
|
object.js_exposed?(method_name)
|
81
81
|
|
data/lib/bowline/generators.rb
CHANGED
data/lib/bowline/initializer.rb
CHANGED
@@ -91,7 +91,7 @@ module Bowline
|
|
91
91
|
end
|
92
92
|
|
93
93
|
def set_load_path
|
94
|
-
load_paths = configuration.
|
94
|
+
load_paths = configuration.autoload_paths
|
95
95
|
load_paths.reverse_each { |dir| $LOAD_PATH.unshift(dir) if File.directory?(dir) }
|
96
96
|
$LOAD_PATH.uniq!
|
97
97
|
end
|
@@ -110,27 +110,22 @@ module Bowline
|
|
110
110
|
# Set the paths from which Bowline will automatically load source files, and
|
111
111
|
# the load_once paths.
|
112
112
|
def set_autoload_paths
|
113
|
-
|
114
|
-
ActiveSupport::Dependencies.
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
Extra items in load_once_paths: #{extra * ','}
|
121
|
-
end_error
|
113
|
+
# Rails 3 master support
|
114
|
+
if ActiveSupport::Dependencies.respond_to?(:autoload_paths)
|
115
|
+
ActiveSupport::Dependencies.autoload_paths = configuration.autoload_paths.uniq
|
116
|
+
ActiveSupport::Dependencies.autoload_once_paths = configuration.autoload_once_paths.uniq
|
117
|
+
else
|
118
|
+
ActiveSupport::Dependencies.load_paths = configuration.autoload_paths.uniq
|
119
|
+
ActiveSupport::Dependencies.load_once_paths = configuration.autoload_once_paths.uniq
|
122
120
|
end
|
123
|
-
|
124
|
-
# Freeze the arrays so future modifications will fail rather than do nothing mysteriously
|
125
|
-
configuration.load_once_paths.freeze
|
126
121
|
end
|
127
122
|
|
128
123
|
def add_plugin_load_paths
|
129
124
|
Dir.glob(File.join(configuration.plugin_glob, 'lib')).sort.each do |path|
|
130
125
|
$LOAD_PATH << path
|
131
|
-
ActiveSupport::Dependencies.
|
126
|
+
ActiveSupport::Dependencies.autoload_paths << path
|
132
127
|
unless configuration.reload_plugins?
|
133
|
-
ActiveSupport::Dependencies.
|
128
|
+
ActiveSupport::Dependencies.autoload_once_paths << path
|
134
129
|
end
|
135
130
|
end
|
136
131
|
$LOAD_PATH.uniq!
|
@@ -242,7 +237,7 @@ module Bowline
|
|
242
237
|
def load_application_first_run
|
243
238
|
first_run = Bowline.root.join("app_first_run")
|
244
239
|
if first_run.exist?
|
245
|
-
first_run.unlink
|
240
|
+
first_run.unlink if Bowline.root.writable_real?
|
246
241
|
Dir.glob(configuration.first_run_glob).sort.each do |initializer|
|
247
242
|
load(initializer)
|
248
243
|
end
|
@@ -413,15 +408,15 @@ module Bowline
|
|
413
408
|
|
414
409
|
# An array of additional paths to prepend to the load path. By default,
|
415
410
|
# all +app+, +lib+, +vendor+ and mock paths are included in this list.
|
416
|
-
attr_accessor :
|
411
|
+
attr_accessor :autoload_paths
|
417
412
|
|
418
413
|
# An array of paths from which Bowline will automatically load from only once.
|
419
414
|
# All elements of this array must also be in +load_paths+.
|
420
|
-
attr_accessor :
|
415
|
+
attr_accessor :autoload_once_paths
|
421
416
|
|
422
417
|
# An array of paths from which Bowline will eager load on boot if cache
|
423
418
|
# classes is enabled. All elements of this array must also be in
|
424
|
-
# +
|
419
|
+
# +autoload_paths+.
|
425
420
|
attr_accessor :eager_load_paths
|
426
421
|
|
427
422
|
# The log level to use for the default Bowline logger.
|
@@ -498,8 +493,8 @@ module Bowline
|
|
498
493
|
set_root_path!
|
499
494
|
|
500
495
|
self.frameworks = default_frameworks
|
501
|
-
self.
|
502
|
-
self.
|
496
|
+
self.autoload_paths = default_autoload_paths
|
497
|
+
self.autoload_once_paths = default_autoload_once_paths
|
503
498
|
self.dependency_loading = default_dependency_loading
|
504
499
|
self.eager_load_paths = default_eager_load_paths
|
505
500
|
self.log_path = default_log_path
|
@@ -572,7 +567,7 @@ module Bowline
|
|
572
567
|
[:active_support, :bowline]
|
573
568
|
end
|
574
569
|
|
575
|
-
def
|
570
|
+
def default_autoload_paths
|
576
571
|
paths = []
|
577
572
|
|
578
573
|
# Followed by the standard includes.
|
@@ -591,7 +586,7 @@ module Bowline
|
|
591
586
|
end
|
592
587
|
|
593
588
|
# Doesn't matter since plugins aren't in load_paths yet.
|
594
|
-
def
|
589
|
+
def default_autoload_once_paths
|
595
590
|
[]
|
596
591
|
end
|
597
592
|
|
data/lib/bowline/tasks/app.rake
CHANGED
@@ -19,16 +19,12 @@ namespace :app do
|
|
19
19
|
app_path = File.join(build_path, "#{config.name}.zip")
|
20
20
|
FileUtils.rm_rf(app_path)
|
21
21
|
|
22
|
-
dirs = Dir[Bowline.root.
|
23
|
-
dirs.delete(build_path.to_s)
|
24
|
-
dirs.delete(Bowline.root.join("log").to_s)
|
25
|
-
dirs.delete(Bowline.root.join(*%w{db migrate}).to_s)
|
26
|
-
dirs.delete_if {|i| i =~ /\.svn|\.DS_Store|\.git/ }
|
22
|
+
dirs = Dir["#{Bowline.root.to_s}/**/**"]
|
27
23
|
|
28
|
-
|
29
|
-
dirs
|
30
|
-
|
31
|
-
dirs
|
24
|
+
dirs.delete_if {|d| d.include?(build_path.to_s) }
|
25
|
+
dirs.delete_if {|d| d.include?(Bowline.root.join("log").to_s) }
|
26
|
+
dirs.delete_if {|d| d.include?(Bowline.root.join(*%w{db migrate}).to_s) }
|
27
|
+
dirs.delete_if {|i| i =~ /\.svn|\.DS_Store|\.git/ }
|
32
28
|
|
33
29
|
Zip::ZipFile.open(app_path, Zip::ZipFile::CREATE) do |zf|
|
34
30
|
# This is horrible - but RubyZIP's API sucks
|
data/lib/bowline/version.rb
CHANGED
data/templates/Gemfile
CHANGED
data/templates/Rakefile
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
# Add your own tasks in files placed in lib/tasks ending in .rake,
|
2
2
|
# for example lib/tasks/foo.rake, and they will automatically be available to Rake.
|
3
3
|
|
4
|
-
require File.join(File.dirname(__FILE__), *%w[config boot])
|
4
|
+
require File.expand_path(File.join(File.dirname(__FILE__), *%w[config boot]))
|
5
5
|
|
6
6
|
require 'rake'
|
7
7
|
require 'bowline/tasks/bowline'
|
data/templates/config/boot.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
# Bootstrap the Bowline environment, frameworks, and default configuration
|
2
|
-
require File.join(File.dirname(__FILE__), 'boot')
|
2
|
+
require File.expand_path(File.join(File.dirname(__FILE__), 'boot'))
|
3
3
|
|
4
4
|
Bowline::Initializer.run do |config|
|
5
5
|
config.name = <%= full_name.inspect %>
|
data/templates/script/build
CHANGED
data/templates/script/console
CHANGED
data/templates/script/generate
CHANGED
data/templates/script/init
CHANGED
data/templates/script/run
CHANGED
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 9
|
8
|
-
-
|
9
|
-
version: 0.9.
|
8
|
+
- 4
|
9
|
+
version: 0.9.4
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Alex MacCaw
|
@@ -14,13 +14,14 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-
|
17
|
+
date: 2010-09-24 00:00:00 +01:00
|
18
18
|
default_executable: bowline-gen
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
21
|
name: templater
|
22
22
|
prerelease: false
|
23
23
|
requirement: &id001 !ruby/object:Gem::Requirement
|
24
|
+
none: false
|
24
25
|
requirements:
|
25
26
|
- - ">="
|
26
27
|
- !ruby/object:Gem::Version
|
@@ -35,6 +36,7 @@ dependencies:
|
|
35
36
|
name: activesupport
|
36
37
|
prerelease: false
|
37
38
|
requirement: &id002 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
38
40
|
requirements:
|
39
41
|
- - ">="
|
40
42
|
- !ruby/object:Gem::Version
|
@@ -42,14 +44,15 @@ dependencies:
|
|
42
44
|
- 3
|
43
45
|
- 0
|
44
46
|
- 0
|
45
|
-
-
|
46
|
-
version: 3.0.0.
|
47
|
+
- beta4
|
48
|
+
version: 3.0.0.beta4
|
47
49
|
type: :runtime
|
48
50
|
version_requirements: *id002
|
49
51
|
- !ruby/object:Gem::Dependency
|
50
52
|
name: rubyzip2
|
51
53
|
prerelease: false
|
52
54
|
requirement: &id003 !ruby/object:Gem::Requirement
|
55
|
+
none: false
|
53
56
|
requirements:
|
54
57
|
- - ">="
|
55
58
|
- !ruby/object:Gem::Version
|
@@ -64,6 +67,7 @@ dependencies:
|
|
64
67
|
name: supermodel
|
65
68
|
prerelease: false
|
66
69
|
requirement: &id004 !ruby/object:Gem::Requirement
|
70
|
+
none: false
|
67
71
|
requirements:
|
68
72
|
- - ">="
|
69
73
|
- !ruby/object:Gem::Version
|
@@ -78,6 +82,7 @@ dependencies:
|
|
78
82
|
name: bowline-bundler
|
79
83
|
prerelease: false
|
80
84
|
requirement: &id005 !ruby/object:Gem::Requirement
|
85
|
+
none: false
|
81
86
|
requirements:
|
82
87
|
- - ">="
|
83
88
|
- !ruby/object:Gem::Version
|
@@ -206,6 +211,7 @@ rdoc_options:
|
|
206
211
|
require_paths:
|
207
212
|
- lib
|
208
213
|
required_ruby_version: !ruby/object:Gem::Requirement
|
214
|
+
none: false
|
209
215
|
requirements:
|
210
216
|
- - ">="
|
211
217
|
- !ruby/object:Gem::Version
|
@@ -213,6 +219,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
213
219
|
- 0
|
214
220
|
version: "0"
|
215
221
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
222
|
+
none: false
|
216
223
|
requirements:
|
217
224
|
- - ">="
|
218
225
|
- !ruby/object:Gem::Version
|
@@ -222,7 +229,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
222
229
|
requirements: []
|
223
230
|
|
224
231
|
rubyforge_project:
|
225
|
-
rubygems_version: 1.3.
|
232
|
+
rubygems_version: 1.3.7
|
226
233
|
signing_key:
|
227
234
|
specification_version: 3
|
228
235
|
summary: Bowline GUI framework
|