rake 0.9.2.2 → 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/CHANGES +4 -0
- data/README.rdoc +10 -20
- data/Rakefile +6 -1
- data/TODO +1 -0
- data/bin/rake +4 -0
- data/doc/command_line_usage.rdoc +61 -12
- data/doc/release_notes/rake-0.9.2.2.rdoc +55 -0
- data/doc/release_notes/rake-0.9.3.rdoc +102 -0
- data/install.rb +1 -1
- data/lib/rake/application.rb +245 -140
- data/lib/rake/backtrace.rb +18 -0
- data/lib/rake/clean.rb +1 -1
- data/lib/rake/cloneable.rb +7 -16
- data/lib/rake/contrib/ftptools.rb +2 -1
- data/lib/rake/contrib/sys.rb +7 -6
- data/lib/rake/dsl_definition.rb +13 -7
- data/lib/rake/ext/module.rb +1 -1
- data/lib/rake/ext/string.rb +2 -1
- data/lib/rake/ext/time.rb +2 -1
- data/lib/rake/file_list.rb +9 -2
- data/lib/rake/file_utils_ext.rb +4 -3
- data/lib/rake/multi_task.rb +2 -5
- data/lib/rake/phony.rb +15 -0
- data/lib/rake/private_reader.rb +20 -0
- data/lib/rake/promise.rb +99 -0
- data/lib/rake/rake_module.rb +8 -0
- data/lib/rake/rdoctask.rb +1 -1
- data/lib/rake/runtest.rb +2 -1
- data/lib/rake/task.rb +29 -7
- data/lib/rake/task_arguments.rb +1 -1
- data/lib/rake/task_manager.rb +1 -1
- data/lib/rake/testtask.rb +8 -1
- data/lib/rake/thread_history_display.rb +48 -0
- data/lib/rake/thread_pool.rb +155 -0
- data/lib/rake/version.rb +6 -4
- data/lib/rake.rb +1 -0
- data/test/helper.rb +57 -0
- data/test/test_private_reader.rb +42 -0
- data/test/test_rake_application.rb +12 -1
- data/test/test_rake_application_options.rb +114 -4
- data/test/test_rake_backtrace.rb +81 -0
- data/test/test_rake_directory_task.rb +16 -5
- data/test/test_rake_file_task.rb +21 -1
- data/test/test_rake_functional.rb +40 -1
- data/test/test_rake_multi_task.rb +8 -0
- data/test/test_rake_reduce_compat.rb +65 -0
- data/test/test_rake_task.rb +50 -1
- data/test/test_rake_thread_pool.rb +123 -0
- data/test/test_thread_history_display.rb +91 -0
- metadata +50 -34
data/CHANGES
CHANGED
|
@@ -8,6 +8,10 @@
|
|
|
8
8
|
* Rake tests are now directory-independent
|
|
9
9
|
* Rake tests are no longer require flexmock
|
|
10
10
|
* Commands constant is no longer polluting top level namespace.
|
|
11
|
+
* Show only the interesting portion of the backtrace by default (James M. Lawrence).
|
|
12
|
+
* Added --reduce-compat optiont to remove backward compatible DSL hacks (James M. Lawrence).
|
|
13
|
+
* lib/rake/file_list.rb (Rake::FileList#egrep): there is no need to
|
|
14
|
+
open files in binary mode. (NAKAMURA Usaku)
|
|
11
15
|
|
|
12
16
|
== Version 0.9.2
|
|
13
17
|
|
data/README.rdoc
CHANGED
|
@@ -31,18 +31,6 @@ Download and install rake with the following.
|
|
|
31
31
|
|
|
32
32
|
gem install rake
|
|
33
33
|
|
|
34
|
-
=== Normal Installation
|
|
35
|
-
|
|
36
|
-
You can download the source tarball of the latest version of Rake from
|
|
37
|
-
|
|
38
|
-
* http://rubyforge.org/project/showfiles.php?group_id=50
|
|
39
|
-
|
|
40
|
-
Extract the tarball and run
|
|
41
|
-
|
|
42
|
-
% ruby install.rb
|
|
43
|
-
|
|
44
|
-
from its distribution directory.
|
|
45
|
-
|
|
46
34
|
== Usage
|
|
47
35
|
|
|
48
36
|
=== Simple Example
|
|
@@ -80,13 +68,13 @@ Type "rake --help" for all available options.
|
|
|
80
68
|
=== More Information
|
|
81
69
|
|
|
82
70
|
* For details on Rake's command-line invocation, read
|
|
83
|
-
doc/command_line_usage.rdoc[
|
|
71
|
+
doc/command_line_usage.rdoc[https://github.com/jimweirich/rake/blob/master/doc/command_line_usage.rdoc]
|
|
84
72
|
* For details on writing Rakefiles, see
|
|
85
|
-
doc/rakefile.rdoc[
|
|
73
|
+
doc/rakefile.rdoc[https://github.com/jimweirich/rake/blob/master/doc/rakefile.rdoc].
|
|
86
74
|
* For the original announcement of Rake, see
|
|
87
|
-
doc/rational.rdoc[
|
|
75
|
+
doc/rational.rdoc[https://github.com/jimweirich/rake/blob/master/doc/rational.rdoc].
|
|
88
76
|
* For a glossary of terms, see
|
|
89
|
-
doc/glossary.rdoc[
|
|
77
|
+
doc/glossary.rdoc[https://github.com/jimweirich/rake/blob/master/doc/glossary.rdoc].
|
|
90
78
|
|
|
91
79
|
== Development
|
|
92
80
|
|
|
@@ -128,8 +116,8 @@ Issues and bug reports can also be tracked here:
|
|
|
128
116
|
* Rake API Documents: http://rake.rubyforge.org
|
|
129
117
|
* Rake Source Code Repo: http://github.com/jimweirich/rake
|
|
130
118
|
* Rake Git Repo Clone URL: git://github.com/jimweirich/rake.git
|
|
131
|
-
* Rake Issue Tracking: http://www.pivotaltracker.com/projects/28469
|
|
132
119
|
* Rake Bug Reports: https://github.com/jimweirich/rake/issues
|
|
120
|
+
* Rake Continuous Build Server: https://travis-ci.org/#!/jimweirich/rake
|
|
133
121
|
|
|
134
122
|
=== Presentations and Articles about Rake
|
|
135
123
|
|
|
@@ -160,6 +148,8 @@ other projects with similar (and not so similar) goals.
|
|
|
160
148
|
|
|
161
149
|
[<b>Tilman Sauerbeck <tilman@code-monkey.de></b>] For the recursive rule patch.
|
|
162
150
|
|
|
151
|
+
[<b>Eric Hodel</b>] For aid in maintaining rake.
|
|
152
|
+
|
|
163
153
|
== License
|
|
164
154
|
|
|
165
155
|
Rake is available under an MIT-style license.
|
|
@@ -185,9 +175,9 @@ jim dot weirich at gmail.com.
|
|
|
185
175
|
|
|
186
176
|
Author:: Jim Weirich <jim.weirich@gmail.com>
|
|
187
177
|
Requires:: Ruby 1.8.6 or later
|
|
188
|
-
License:: Copyright 2003-
|
|
189
|
-
Released under an MIT-style license. See the LICENSE
|
|
190
|
-
included in the distribution.
|
|
178
|
+
License:: Copyright 2003-2011 by Jim Weirich.
|
|
179
|
+
Released under an MIT-style license. See the MIT-LICENSE
|
|
180
|
+
file included in the distribution.
|
|
191
181
|
|
|
192
182
|
== Warranty
|
|
193
183
|
|
data/Rakefile
CHANGED
|
@@ -60,6 +60,7 @@ task :default => :test
|
|
|
60
60
|
|
|
61
61
|
Rake::TestTask.new do |t|
|
|
62
62
|
files = FileList['test/helper.rb', 'test/test_*.rb']
|
|
63
|
+
t.loader = :testrb
|
|
63
64
|
t.test_files = files
|
|
64
65
|
t.libs << "."
|
|
65
66
|
t.warning = true
|
|
@@ -141,7 +142,11 @@ end
|
|
|
141
142
|
PKG_FILES = FileList[
|
|
142
143
|
'.gemtest',
|
|
143
144
|
'install.rb',
|
|
144
|
-
'
|
|
145
|
+
'CHANGES',
|
|
146
|
+
'MIT-LICENSE',
|
|
147
|
+
'README.rdoc',
|
|
148
|
+
'Rakefile',
|
|
149
|
+
'TODO',
|
|
145
150
|
'bin/rake',
|
|
146
151
|
'lib/**/*.rb',
|
|
147
152
|
'test/**/*.rb',
|
data/TODO
CHANGED
data/bin/rake
CHANGED
data/doc/command_line_usage.rdoc
CHANGED
|
@@ -11,6 +11,16 @@ Options are:
|
|
|
11
11
|
during the execution of the <b>rake</b> command. You can access
|
|
12
12
|
the value by using ENV['<em>name</em>'].
|
|
13
13
|
|
|
14
|
+
[<tt>--all</tt> (-A)]
|
|
15
|
+
Used in combination with the -T and -D options, will force
|
|
16
|
+
those options to show all the tasks, even the ones without comments.
|
|
17
|
+
|
|
18
|
+
[<tt>--backtrace</tt> _output_ (-n)]
|
|
19
|
+
Enable a full backtrace (i.e. like --trace, but without the task
|
|
20
|
+
tracing details). The backtrace output will be directed to stderr
|
|
21
|
+
by default. If the options _output_ parameter is set to "stdout",
|
|
22
|
+
then the output will be directed to standard output.
|
|
23
|
+
|
|
14
24
|
[<tt>--classic-namespace</tt> (-n)]
|
|
15
25
|
Import the Task, FileTask, and FileCreateTask into the top-level
|
|
16
26
|
scope to be compatible with older versions of Rake. Alternatively
|
|
@@ -18,6 +28,11 @@ Options are:
|
|
|
18
28
|
'rake/classic_namespace'</code> in your Rakefile to get the
|
|
19
29
|
classic behavior.
|
|
20
30
|
|
|
31
|
+
[<tt>--comments</tt>]
|
|
32
|
+
Used in combination with the -W options to force the output to
|
|
33
|
+
contain commented options only. This is the reverse of
|
|
34
|
+
<tt>--all</tt>.
|
|
35
|
+
|
|
21
36
|
[<tt>--describe</tt> _pattern_ (-D)]
|
|
22
37
|
Describe the tasks (matching optional PATTERN), then exit.
|
|
23
38
|
|
|
@@ -31,15 +46,40 @@ Options are:
|
|
|
31
46
|
[<tt>--execute-print</tt> _code_ (-p)]
|
|
32
47
|
Execute some Ruby code, print the result, and exit.
|
|
33
48
|
|
|
34
|
-
[<tt>--execute-continue</tt> _code_ (-
|
|
49
|
+
[<tt>--execute-continue</tt> _code_ (-E)]
|
|
35
50
|
Execute some Ruby code, then continue with normal task processing.
|
|
36
51
|
|
|
37
52
|
[<tt>--help</tt> (-H)]
|
|
38
53
|
Display some help text and exit.
|
|
39
54
|
|
|
55
|
+
[<tt>--jobs</tt> _number_ (-j)]
|
|
56
|
+
Specifies the number of active concurrent tasks used. The
|
|
57
|
+
suggested value is equal to the number of CPUs. The concurrent
|
|
58
|
+
tasks are used to execute the <tt>multitask</tt> prerequisites.
|
|
59
|
+
Also see the <tt>-m</tt> option which turns all tasks into
|
|
60
|
+
multitasks.
|
|
61
|
+
|
|
62
|
+
Sample values:
|
|
63
|
+
(no -j) : unlimited concurrent tasks (standard rake behavior)
|
|
64
|
+
-j : 2 concurrent tasks (exact number may change)
|
|
65
|
+
-j 16 : 16 concurrent tasks
|
|
66
|
+
|
|
67
|
+
[<tt>--job-stats</tt> _level_]
|
|
68
|
+
|
|
69
|
+
Display job statistics at the completion of the run. By default,
|
|
70
|
+
this will display the requested number of active tasks (from the
|
|
71
|
+
-j options) and the maximum number of tasks in play at any given
|
|
72
|
+
time.
|
|
73
|
+
|
|
74
|
+
If the optional _level_ is <tt>history</tt>, then a complete trace
|
|
75
|
+
of task history will be displayed on standard output.
|
|
76
|
+
|
|
40
77
|
[<tt>--libdir</tt> _directory_ (-I)]
|
|
41
78
|
Add _directory_ to the list of directories searched for require.
|
|
42
79
|
|
|
80
|
+
[<tt>--multitask</tt> (-m)]
|
|
81
|
+
Treat all tasks as multitasks. ('make/drake' semantics)
|
|
82
|
+
|
|
43
83
|
[<tt>--nosearch</tt> (-N)]
|
|
44
84
|
Do not search for a Rakefile in parent directories.
|
|
45
85
|
|
|
@@ -60,6 +100,16 @@ Options are:
|
|
|
60
100
|
[<tt>--rakelibdir</tt> _rakelibdir_ (-R)]
|
|
61
101
|
Auto-import any .rake files in RAKELIBDIR. (default is 'rakelib')
|
|
62
102
|
|
|
103
|
+
[<tt>--reduce-compat</tt>]
|
|
104
|
+
|
|
105
|
+
Remove the DSL commands from the Object inheritance hierarchy and
|
|
106
|
+
do not define top level constants. This reduces the backwards
|
|
107
|
+
compatibility of Rake, but allows rake to be used with software
|
|
108
|
+
that would otherwise have conflicting definitions.
|
|
109
|
+
|
|
110
|
+
*NOTE:* The next major version of Rake will only be able to be run
|
|
111
|
+
in "reduce-compat" mode.
|
|
112
|
+
|
|
63
113
|
[<tt>--require</tt> _name_ (-r)]
|
|
64
114
|
Require _name_ before executing the Rakefile.
|
|
65
115
|
|
|
@@ -69,6 +119,11 @@ Options are:
|
|
|
69
119
|
[<tt>--silent (-s)</tt>]
|
|
70
120
|
Like --quiet, but also suppresses the 'in directory' announcement.
|
|
71
121
|
|
|
122
|
+
[<tt>--suppress-backtrace _pattern_ </tt>]
|
|
123
|
+
Line matching the regular expression _pattern_ will be removed
|
|
124
|
+
from the backtrace output. Note that the --backtrace option is the
|
|
125
|
+
full backtrace without these lines suppressed.
|
|
126
|
+
|
|
72
127
|
[<tt>--system</tt> (-g)]
|
|
73
128
|
Use the system wide (global) rakefiles. The project Rakefile is
|
|
74
129
|
ignored. By default, the system wide rakefiles are used only if no
|
|
@@ -85,16 +140,6 @@ Options are:
|
|
|
85
140
|
are defined using the "desc" command. If a pattern is given, then
|
|
86
141
|
only tasks matching the pattern are displayed.
|
|
87
142
|
|
|
88
|
-
[<tt>--no-top-level-dsl</tt> (-X)]
|
|
89
|
-
Do not put the Rake DSL commands into the top level scope.
|
|
90
|
-
|
|
91
|
-
[<tt>--top-level-dsl</tt>]
|
|
92
|
-
Put the Rake DSL commands into the top level scope (default).
|
|
93
|
-
|
|
94
|
-
NOTE: Although currently Rake defaults to its DSL in the top level
|
|
95
|
-
scope, the plan is to deprecate this in the future and default ot
|
|
96
|
-
having the DSL commands *not* appear in the top level scope.
|
|
97
|
-
|
|
98
143
|
[<tt>--trace</tt> (-t)]
|
|
99
144
|
Turn on invoke/execute tracing. Also enable full backtrace on
|
|
100
145
|
errors.
|
|
@@ -107,7 +152,11 @@ Options are:
|
|
|
107
152
|
|
|
108
153
|
[<tt>--where</tt> <em>pattern</em> (-W)]
|
|
109
154
|
Display tasks that match <em>pattern</em> and the file and line
|
|
110
|
-
number where the task is defined.
|
|
155
|
+
number where the task is defined. By default this option will
|
|
156
|
+
display all tasks, not just the tasks that have descriptions.
|
|
157
|
+
|
|
158
|
+
[<tt>--no-deprecation-warnings</tt> (-W)]
|
|
159
|
+
Do not display the deprecation warnings.
|
|
111
160
|
|
|
112
161
|
In addition, any command line option of the form
|
|
113
162
|
<em>VAR</em>=<em>VALUE</em> will be added to the environment hash
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
= Rake 0.9.3 Released
|
|
2
|
+
|
|
3
|
+
Rake version 0.9.3 is mainly bug fixes.
|
|
4
|
+
|
|
5
|
+
== Changes
|
|
6
|
+
|
|
7
|
+
* The rake test loader now removes arguments it has processed. Issue #51
|
|
8
|
+
* Rake::TaskArguments now responds to #values_at
|
|
9
|
+
* RakeFileUtils.verbose_flag = nil silences output the same as 0.8.7
|
|
10
|
+
* Rake tests are now directory-independent
|
|
11
|
+
* Rake tests are no longer require flexmock
|
|
12
|
+
* Commands constant is no longer polluting top level namespace.
|
|
13
|
+
* Show only the interesting portion of the backtrace by default (James M. Lawrence).
|
|
14
|
+
* Added --reduce-compat option to remove backward compatible DSL hacks (James M. Lawrence).
|
|
15
|
+
|
|
16
|
+
== What is Rake
|
|
17
|
+
|
|
18
|
+
Rake is a build tool similar to the make program in many ways. But
|
|
19
|
+
instead of cryptic make recipes, Rake uses standard Ruby code to
|
|
20
|
+
declare tasks and dependencies. You have the full power of a modern
|
|
21
|
+
scripting language built right into your build tool.
|
|
22
|
+
|
|
23
|
+
== Availability
|
|
24
|
+
|
|
25
|
+
The easiest way to get and install rake is via RubyGems ...
|
|
26
|
+
|
|
27
|
+
gem install rake (you may need root/admin privileges)
|
|
28
|
+
|
|
29
|
+
Otherwise, you can get it from the more traditional places:
|
|
30
|
+
|
|
31
|
+
Home Page:: http://rake.rubyforge.org/
|
|
32
|
+
Download:: http://rubyforge.org/project/showfiles.php?group_id=50
|
|
33
|
+
GitHub:: git://github.com/jimweirich/rake.git
|
|
34
|
+
|
|
35
|
+
== Thanks
|
|
36
|
+
|
|
37
|
+
As usual, it was input from users that drove a alot of these changes. The
|
|
38
|
+
following people either contributed patches, made suggestions or made
|
|
39
|
+
otherwise helpful comments. Thanks to ...
|
|
40
|
+
|
|
41
|
+
* James M. Lawrence (quix)
|
|
42
|
+
* Roger Pack
|
|
43
|
+
* Cezary Baginski
|
|
44
|
+
* Sean Scot August Moon
|
|
45
|
+
* R.T. Lechow
|
|
46
|
+
* Alex Chaffee
|
|
47
|
+
* James Tucker
|
|
48
|
+
* Matthias Lüdtke
|
|
49
|
+
* Santiago Pastorino
|
|
50
|
+
|
|
51
|
+
Also, bit thanks to Eric Hodel for assisting with getting this release
|
|
52
|
+
out the door (where "assisting" includes, but is not by any means
|
|
53
|
+
limited to, "pushing" me to get it done).
|
|
54
|
+
|
|
55
|
+
-- Jim Weirich
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
= Rake 0.9.3 Released
|
|
2
|
+
|
|
3
|
+
Rake version 0.9.3 contains some new, backwards compatible features and
|
|
4
|
+
a number of bug fixes.
|
|
5
|
+
|
|
6
|
+
== Changes
|
|
7
|
+
|
|
8
|
+
=== New Features
|
|
9
|
+
|
|
10
|
+
* Multitask tasks now use a thread pool. Use -j to limit the number of
|
|
11
|
+
available threads.
|
|
12
|
+
|
|
13
|
+
* Use -m to turn regular tasks into multitasks (use at your own risk).
|
|
14
|
+
|
|
15
|
+
* You can now do "Rake.add_rakelib 'dir'" in your Rakefile to
|
|
16
|
+
programatically add rake task libraries.
|
|
17
|
+
|
|
18
|
+
* You can specific backtrace suppression patterns (see
|
|
19
|
+
--supress-backtrace)
|
|
20
|
+
|
|
21
|
+
* Directory tasks can now take prerequisites and actions
|
|
22
|
+
|
|
23
|
+
* Use --backtrace to request a full backtrace without the task trace.
|
|
24
|
+
|
|
25
|
+
* You can say "--backtrace=stdout" and "--trace=stdout" to route trace
|
|
26
|
+
output to standard output rather than standard error.
|
|
27
|
+
|
|
28
|
+
* Optional 'phony' target (enable with 'require 'rake/phony'") for
|
|
29
|
+
special purpose builds.
|
|
30
|
+
|
|
31
|
+
* Task#clear now clears task comments as well as actions and
|
|
32
|
+
prerequisites. Task#clear_comment will specifically target comments.
|
|
33
|
+
|
|
34
|
+
* The --all option will force -T and -D to consider all the tasks,
|
|
35
|
+
with and without descriptions.
|
|
36
|
+
|
|
37
|
+
=== Bug Fixes
|
|
38
|
+
|
|
39
|
+
* Semi-colons in windows rakefile paths now work.
|
|
40
|
+
|
|
41
|
+
* Improved Control-C support when invoking multiple test suites.
|
|
42
|
+
|
|
43
|
+
* egrep method now reads files in text mode (better support for
|
|
44
|
+
Windows)
|
|
45
|
+
|
|
46
|
+
* Better deprecation line number reporting.
|
|
47
|
+
|
|
48
|
+
* The -W option now works with all tasks, whether they have a
|
|
49
|
+
description or not.
|
|
50
|
+
|
|
51
|
+
* File globs in rake should not be sorted alphabetically, independent
|
|
52
|
+
of file system and platform.
|
|
53
|
+
|
|
54
|
+
* Numerous internal improvements.
|
|
55
|
+
|
|
56
|
+
* Documentation typos and fixes.
|
|
57
|
+
|
|
58
|
+
== What is Rake
|
|
59
|
+
|
|
60
|
+
Rake is a build tool similar to the make program in many ways. But
|
|
61
|
+
instead of cryptic make recipes, Rake uses standard Ruby code to
|
|
62
|
+
declare tasks and dependencies. You have the full power of a modern
|
|
63
|
+
scripting language built right into your build tool.
|
|
64
|
+
|
|
65
|
+
== Availability
|
|
66
|
+
|
|
67
|
+
The easiest way to get and install rake is via RubyGems ...
|
|
68
|
+
|
|
69
|
+
gem install rake (you may need root/admin privileges)
|
|
70
|
+
|
|
71
|
+
Otherwise, you can get it from the more traditional places:
|
|
72
|
+
|
|
73
|
+
Home Page:: http://github.com/jimweirich/rake
|
|
74
|
+
Download:: http://rubyforge.org/project/showfiles.php?group_id=50
|
|
75
|
+
GitHub:: git://github.com/jimweirich/rake.git
|
|
76
|
+
|
|
77
|
+
== Thanks
|
|
78
|
+
|
|
79
|
+
As usual, it was input from users that drove a alot of these changes. The
|
|
80
|
+
following people either contributed patches, made suggestions or made
|
|
81
|
+
otherwise helpful comments. Thanks to ...
|
|
82
|
+
|
|
83
|
+
* Aaron Patterson
|
|
84
|
+
* Dylan Smith
|
|
85
|
+
* Jo Liss
|
|
86
|
+
* Jonas Pfenniger
|
|
87
|
+
* Kazuki Tsujimoto
|
|
88
|
+
* Michael Bishop
|
|
89
|
+
* Michael Elufimov
|
|
90
|
+
* NAKAMURA Usaku
|
|
91
|
+
* Ryan Davis
|
|
92
|
+
* Sam Grönblom
|
|
93
|
+
* Sam Phippen
|
|
94
|
+
* Sergio Wong
|
|
95
|
+
* Tay Ray Chuan
|
|
96
|
+
* grosser
|
|
97
|
+
* quix
|
|
98
|
+
|
|
99
|
+
Also, many thanks to Eric Hodel for assisting with getting this release
|
|
100
|
+
out the door.
|
|
101
|
+
|
|
102
|
+
-- Jim Weirich
|