sprout-as2-bundle 0.1.13 → 0.1.18
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/sprout/as2/version.rb +1 -1
- data/lib/sprout/generators/project/project_generator.rb +1 -1
- data/lib/sprout/generators/project/templates/ProjectSprouts.png +0 -0
- data/lib/sprout/generators/project/templates/rakefile.rb +24 -23
- data/lib/sprout/tasks/mtasc_doc.rb +1 -1
- data/lib/sprout/tasks/swfmill_doc.rb +1 -1
- data/rakefile.rb +1 -1
- metadata +5 -4
- data/lib/sprout/generators/project/templates/ProjectSprouts.jpg +0 -0
data/lib/sprout/as2/version.rb
CHANGED
@@ -17,7 +17,7 @@ class ProjectGenerator < Sprout::Generator::NamedBase # :nodoc:
|
|
17
17
|
m.directory File.join(base, 'src')
|
18
18
|
m.directory File.join(base, 'test')
|
19
19
|
|
20
|
-
m.file 'ProjectSprouts.
|
20
|
+
m.file 'ProjectSprouts.png', File.join(base, 'assets/skins', project_name + 'Skin', 'ProjectSprouts.png')
|
21
21
|
m.template 'rakefile.rb', File.join(base, "rakefile.rb")
|
22
22
|
m.template 'README.txt', File.join(base, "README.txt")
|
23
23
|
|
Binary file
|
@@ -1,23 +1,26 @@
|
|
1
1
|
require 'sprout'
|
2
|
+
# Optionally load gems from your custom server:
|
3
|
+
# set_sources 'http://www.yourdomain.com'
|
2
4
|
sprout 'as2'
|
3
5
|
|
4
6
|
############################################
|
5
7
|
# Uncomment and modify any of the following:
|
6
|
-
|
7
|
-
model.project_name = '<%= project_name %>'
|
8
|
-
|
9
|
-
#
|
10
|
-
# model.
|
11
|
-
# model.
|
12
|
-
# model.
|
13
|
-
# model.
|
14
|
-
# model.
|
15
|
-
|
16
|
-
model.
|
8
|
+
Sprout::ProjectModel.setup do |model|
|
9
|
+
model.project_name = '<%= project_name %>'
|
10
|
+
# Default Values:
|
11
|
+
# model.src_dir = 'src'
|
12
|
+
# model.lib_dir = 'lib'
|
13
|
+
# model.swc_dir = 'lib'
|
14
|
+
# model.bin_dir = 'bin'
|
15
|
+
# model.test_dir = 'test'
|
16
|
+
# model.asset_dir = 'assets'
|
17
|
+
model.language = 'as2'
|
18
|
+
model.output = "#{model.bin_dir}/<%= project_name %>.swf"
|
19
|
+
model.test_output = "#{model.bin_dir}/<%= project_name %>Runner.swf"
|
20
|
+
model.skin_output = "#{model.skin_dir}/<%= project_name %>Skin.swf"
|
21
|
+
end
|
17
22
|
|
18
|
-
|
19
|
-
test_output = "#{model.bin_dir}/<%= project_name %>Runner.swf"
|
20
|
-
skin_output = "#{model.skin_dir}/<%= project_name %>Skin.swf"
|
23
|
+
model = Sprout::ProjectModel.instance
|
21
24
|
|
22
25
|
############################################
|
23
26
|
# Set up remote library tasks
|
@@ -28,12 +31,10 @@ skin_output = "#{model.skin_dir}/<%= project_name %>Skin.swf"
|
|
28
31
|
# task name will also be the folder name that
|
29
32
|
# will be added to ProjectModel.lib_dir
|
30
33
|
# For a complete list of available sprout gems:
|
31
|
-
# http://
|
34
|
+
# http://rubyforge.org/frs/?group_id=3688
|
32
35
|
# You can also search that list directly from a
|
33
36
|
# terminal as follows:
|
34
|
-
# gem search -r library
|
35
|
-
# Any gems with 'sprout-' prefix and '-library'
|
36
|
-
# suffix can be be used as a library task.
|
37
|
+
# gem search -r sprout-*library
|
37
38
|
|
38
39
|
library :asunit25
|
39
40
|
|
@@ -45,7 +46,7 @@ library :asunit25
|
|
45
46
|
# "Some String with: #{variable}"
|
46
47
|
|
47
48
|
desc "Compile and run main application"
|
48
|
-
flashplayer :run => output
|
49
|
+
flashplayer :run => model.output
|
49
50
|
|
50
51
|
# Make 'run' the default task
|
51
52
|
task :default => :run
|
@@ -54,12 +55,12 @@ task :default => :run
|
|
54
55
|
# Launch the test suites using the Flash Player
|
55
56
|
|
56
57
|
desc "Compile and run test suites"
|
57
|
-
flashplayer :test => test_output
|
58
|
+
flashplayer :test => model.test_output
|
58
59
|
|
59
60
|
############################################
|
60
61
|
# Compile the skin using SWFMill
|
61
62
|
|
62
|
-
swfmill skin_output do |t|
|
63
|
+
swfmill model.skin_output do |t|
|
63
64
|
t.input = "#{model.skin_dir}/<%= project_name %>Skin"
|
64
65
|
end
|
65
66
|
|
@@ -70,7 +71,7 @@ end
|
|
70
71
|
# to the compiler source or swc paths
|
71
72
|
|
72
73
|
desc "Compile application"
|
73
|
-
mtasc output => [skin_output] do |t|
|
74
|
+
mtasc model.output => [model.skin_output] do |t|
|
74
75
|
t.main = true
|
75
76
|
t.frame = 2
|
76
77
|
t.input = "#{model.src_dir}/<%= project_name %>.as"
|
@@ -79,7 +80,7 @@ end
|
|
79
80
|
|
80
81
|
############################################
|
81
82
|
# Compile test harness using mtasc
|
82
|
-
mtasc test_output => [:asunit25, skin_output] do |t|
|
83
|
+
mtasc model.test_output => [:asunit25, model.skin_output] do |t|
|
83
84
|
t.main = true
|
84
85
|
t.input = "#{model.test_dir}/<%= project_name %>Runner.as"
|
85
86
|
t.class_path << model.src_dir
|
@@ -1,5 +1,5 @@
|
|
1
1
|
module Sprout
|
2
|
-
class MTASCTask
|
2
|
+
class MTASCTask < ToolTask
|
3
3
|
# Add a directory path to the class path. This is the list of directories that MTASC will use to look for .as files. You can add as many class_path values as you like. This parameter is an Array, so be sure to append rather than overwrite.
|
4
4
|
#
|
5
5
|
# Even though the official MTASC compiler accepts the +cp+ paramter, we have aliased it as +class_path+, you can use either name in your scripts.
|
@@ -1,5 +1,5 @@
|
|
1
1
|
module Sprout
|
2
|
-
class SWFMillTask
|
2
|
+
class SWFMillTask < ToolTask
|
3
3
|
# Set the SWFMill simple flag. This setting will determine what kind of xml document the compiler expects. Unless you really know what you're doing with SWFMill, this setting will usually be left alone.
|
4
4
|
def simple=(boolean)
|
5
5
|
@simple = boolean
|
data/rakefile.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sprout-as2-bundle
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.18
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pattern Park
|
@@ -9,7 +9,7 @@ autorequire: sprout/as2
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2008-02-
|
12
|
+
date: 2008-02-12 00:00:00 -08:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -19,7 +19,7 @@ dependencies:
|
|
19
19
|
requirements:
|
20
20
|
- - ">="
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: 0.7.
|
22
|
+
version: 0.7.158
|
23
23
|
version:
|
24
24
|
- !ruby/object:Gem::Dependency
|
25
25
|
name: sprout-flashplayer-bundle
|
@@ -40,6 +40,7 @@ extra_rdoc_files:
|
|
40
40
|
- README
|
41
41
|
files:
|
42
42
|
- lib
|
43
|
+
- pkg
|
43
44
|
- rakefile.rb
|
44
45
|
- README
|
45
46
|
- samples
|
@@ -65,7 +66,7 @@ files:
|
|
65
66
|
- lib/sprout/generators/project/templates/DefaultSkin.as
|
66
67
|
- lib/sprout/generators/project/templates/generate
|
67
68
|
- lib/sprout/generators/project/templates/MainClass.as
|
68
|
-
- lib/sprout/generators/project/templates/ProjectSprouts.
|
69
|
+
- lib/sprout/generators/project/templates/ProjectSprouts.png
|
69
70
|
- lib/sprout/generators/project/templates/rakefile.rb
|
70
71
|
- lib/sprout/generators/project/templates/README.txt
|
71
72
|
- lib/sprout/generators/project/templates/SWFMillTemplate.erb
|
Binary file
|