inochi 1.1.1 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- data/CREDITS +17 -1
- data/bin/inochi +19 -539
- data/lib/inochi.rb +1 -41
- data/lib/inochi/engine.rb +101 -0
- data/lib/inochi/generate.rb +52 -0
- data/lib/inochi/inochi.rb +109 -0
- data/lib/inochi/tasks/ann.rake +230 -0
- data/lib/inochi/tasks/api.rake +28 -0
- data/lib/inochi/tasks/gem.rake +46 -0
- data/lib/inochi/tasks/init.rake +38 -0
- data/lib/inochi/tasks/man.rake +78 -0
- data/lib/inochi/tasks/project.rake +25 -0
- data/lib/inochi/tasks/pub.rake +130 -0
- data/lib/inochi/templates/CREDITS.rbs +18 -0
- data/lib/inochi/templates/EXAMPLES.rbs +24 -0
- data/lib/inochi/templates/FURTHER.rbs +17 -0
- data/lib/inochi/templates/HACKING.rbs +92 -0
- data/lib/inochi/templates/HISTORY.rbs +55 -0
- data/lib/inochi/templates/LICENSE.rbs +15 -0
- data/lib/inochi/templates/MANUAL.rbs +27 -0
- data/lib/inochi/templates/README.rbs +60 -0
- data/lib/inochi/templates/USAGE.rbs +23 -0
- data/lib/inochi/templates/command.rbs +23 -0
- data/lib/inochi/templates/inochi.opts.rbs +43 -0
- data/lib/inochi/templates/inochi.rb.rbs +102 -0
- data/lib/inochi/templates/library.rbs +7 -0
- data/lib/inochi/templates/library_test.rb.rbs +3 -0
- data/lib/inochi/templates/test_helper.rb.rbs +3 -0
- data/lib/inochi/templates/test_runner.rbs +25 -0
- data/{doc → logo}/inochi.png +0 -0
- data/man.html +959 -0
- data/man/man1/inochi.1.gz +0 -0
- metadata +129 -198
- data/doc/README +0 -6
- data/doc/api/apple-touch-icon.png +0 -0
- data/doc/api/classes/Array.html +0 -370
- data/doc/api/classes/File.html +0 -110
- data/doc/api/classes/Inochi.html +0 -1477
- data/doc/api/classes/Inochi/Manual.html +0 -157
- data/doc/api/classes/Inochi/Phrases.html +0 -331
- data/doc/api/classes/Inochi/Version.html +0 -190
- data/doc/api/classes/TempDir.html +0 -164
- data/doc/api/created.rid +0 -1
- data/doc/api/css/main.css +0 -263
- data/doc/api/css/panel.css +0 -383
- data/doc/api/css/reset.css +0 -53
- data/doc/api/favicon.ico +0 -0
- data/doc/api/files/CREDITS.html +0 -61
- data/doc/api/files/LICENSE.html +0 -76
- data/doc/api/files/lib/inochi/book_rb.html +0 -106
- data/doc/api/files/lib/inochi/init_rb.html +0 -66
- data/doc/api/files/lib/inochi/main_rb.html +0 -52
- data/doc/api/files/lib/inochi/rake_rb.html +0 -52
- data/doc/api/files/lib/inochi/test/bacon_rb.html +0 -67
- data/doc/api/files/lib/inochi/test/context_rb.html +0 -69
- data/doc/api/files/lib/inochi/test/dfect_rb.html +0 -67
- data/doc/api/files/lib/inochi/test/matchy_rb.html +0 -69
- data/doc/api/files/lib/inochi/test/minitest_rb.html +0 -71
- data/doc/api/files/lib/inochi/test/mocha_rb.html +0 -67
- data/doc/api/files/lib/inochi/test/rspec_rb.html +0 -67
- data/doc/api/files/lib/inochi/test/shoulda_rb.html +0 -67
- data/doc/api/files/lib/inochi/test/test_spec_rb.html +0 -67
- data/doc/api/files/lib/inochi/test/test_unit_rb.html +0 -67
- data/doc/api/files/lib/inochi/util/combo_rb.html +0 -59
- data/doc/api/files/lib/inochi/util/tempdir_rb.html +0 -68
- data/doc/api/files/lib/inochi/util_rb.html +0 -59
- data/doc/api/files/lib/inochi_rb.html +0 -76
- data/doc/api/i/arrows.png +0 -0
- data/doc/api/i/results_bg.png +0 -0
- data/doc/api/i/tree_bg.png +0 -0
- data/doc/api/index.html +0 -14
- data/doc/api/js/jquery-1.3.2.min.js +0 -19
- data/doc/api/js/jquery-effect.js +0 -593
- data/doc/api/js/main.js +0 -22
- data/doc/api/js/searchdoc.js +0 -628
- data/doc/api/panel/index.html +0 -71
- data/doc/api/panel/search_index.js +0 -1
- data/doc/api/panel/tree.js +0 -1
- data/doc/history.erb +0 -268
- data/doc/index.erb +0 -11
- data/doc/index.html +0 -3179
- data/doc/inochi.svg +0 -405
- data/doc/intro.erb +0 -87
- data/doc/setup.erb +0 -105
- data/doc/usage.erb +0 -641
- data/lib/inochi/book.rb +0 -91
- data/lib/inochi/init.rb +0 -256
- data/lib/inochi/main.rb +0 -85
- data/lib/inochi/rake.rb +0 -902
- data/lib/inochi/test/bacon.rb +0 -3
- data/lib/inochi/test/context.rb +0 -4
- data/lib/inochi/test/dfect.rb +0 -3
- data/lib/inochi/test/matchy.rb +0 -4
- data/lib/inochi/test/minitest.rb +0 -7
- data/lib/inochi/test/mocha.rb +0 -3
- data/lib/inochi/test/rspec.rb +0 -3
- data/lib/inochi/test/shoulda.rb +0 -3
- data/lib/inochi/test/test_spec.rb +0 -3
- data/lib/inochi/test/test_unit.rb +0 -3
- data/lib/inochi/util.rb +0 -99
- data/lib/inochi/util/combo.rb +0 -191
- data/lib/inochi/util/tempdir.rb +0 -29
- data/rakefile +0 -12
- data/test/inochi.rb +0 -111
data/CREDITS
CHANGED
@@ -1 +1,17 @@
|
|
1
|
-
|
1
|
+
%#----------------------------------------------------------------------------
|
2
|
+
## CREDITS
|
3
|
+
%#----------------------------------------------------------------------------
|
4
|
+
|
5
|
+
Suraj N. Kurapati,
|
6
|
+
Peileppe Production,
|
7
|
+
Florian Gilcher
|
8
|
+
|
9
|
+
### Logo
|
10
|
+
%< "logo/README"
|
11
|
+
|
12
|
+
%#----------------------------------------------------------------------------
|
13
|
+
## LICENSE
|
14
|
+
%#----------------------------------------------------------------------------
|
15
|
+
|
16
|
+
%# See the file named "LICENSE".
|
17
|
+
%< "LICENSE"
|
data/bin/inochi
CHANGED
@@ -1,543 +1,23 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
#
|
3
|
-
# Generates a project scaffold using the given information.
|
4
|
-
#
|
5
|
-
# Existing files are backed up and NOT overwritten. It is your
|
6
|
-
# responsibility to merge changes (see the --merger option)
|
7
|
-
# between the existing files and the newly generated files.
|
8
|
-
#
|
9
|
-
# This tool announces its progress as it runs, using these indicators:
|
10
|
-
#
|
11
|
-
# create: A file is being created because it does not exist.
|
12
|
-
#
|
13
|
-
# skip: A file is being skipped because it is already up to date.
|
14
|
-
#
|
15
|
-
# update: A file is being updated because it is out of date. A text
|
16
|
-
# merging tool (see the --merger option) will be launched to
|
17
|
-
# transfer content from the old file (*.old) and the new file
|
18
|
-
# (*.new) to the out of date file. If a text merging tool is
|
19
|
-
# not specified, then you will have to do the merging by hand.
|
20
|
-
#
|
21
|
-
# Usage:
|
22
|
-
#
|
23
|
-
# inochi [Options] ProjectName [ProgramName]
|
24
|
-
#
|
25
|
-
#
|
26
|
-
# ProjectName: Name of your project, which will be normalized
|
27
|
-
# into the name of a Ruby module that will serve
|
28
|
-
# as a namespace for all code in your project.
|
29
|
-
#
|
30
|
-
# ProgramName: (Optional) Name of the main project executable,
|
31
|
-
# which also serves as the name of the generated
|
32
|
-
# project directory and the main project library.
|
33
|
-
#
|
34
|
-
#
|
35
|
-
# Options:
|
36
|
-
#
|
37
2
|
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
# utility logic
|
51
|
-
require 'fileutils'
|
52
|
-
require 'digest/sha1'
|
53
|
-
|
54
|
-
# Notify the user about some action being performed.
|
55
|
-
def notify *args # :nodoc:
|
56
|
-
printf "%8s %s\n", *args
|
57
|
-
end
|
58
|
-
|
59
|
-
# Writes the given contents to the file at the given path. If the given path
|
60
|
-
# already exists, then a backup is created before invoking the merging tool.
|
61
|
-
def create path, body, merger = @options[:merger]
|
62
|
-
# remove leading space
|
63
|
-
body = body.to_s
|
64
|
-
data = body.strip.gsub(/^#{body[/^[ \t]*(?=\S)/]}/, '') << "\n"
|
65
|
-
|
66
|
-
if File.exist? path
|
67
|
-
old_digest = Digest::SHA1.digest(File.read(path))
|
68
|
-
new_digest = Digest::SHA1.digest(data)
|
69
|
-
|
70
|
-
if old_digest == new_digest
|
71
|
-
notify :skip, path
|
72
|
-
else
|
73
|
-
notify :update, path
|
74
|
-
cur, old, new = path, "#{path}.old", "#{path}.new"
|
75
|
-
|
76
|
-
FileUtils.cp cur, old, :preserve => true
|
77
|
-
File.write new, data
|
78
|
-
|
79
|
-
system merger, old, new, cur if merger
|
80
|
-
end
|
81
|
-
else
|
82
|
-
notify :create, path
|
83
|
-
FileUtils.mkdir_p File.dirname(path)
|
84
|
-
File.write path, data
|
3
|
+
require 'inochi'
|
4
|
+
|
5
|
+
if ARGV.delete('-h') or ARGV.delete('--help')
|
6
|
+
# try to display UNIX version of help manual
|
7
|
+
man_path = File.join(Inochi::INSTDIR, 'man')
|
8
|
+
unless system 'man', '-M', man_path, '-a', 'inochi'
|
9
|
+
# try to display HTML version of help manual
|
10
|
+
man_html = man_path + '.html'
|
11
|
+
unless %w[$BROWSER open start].any? {|b| system "#{b} #{man_html}" }
|
12
|
+
# no luck; direct user to project website
|
13
|
+
puts "See #{Inochi::WEBSITE}"
|
85
14
|
end
|
86
15
|
end
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
project_symbol = Inochi.calc_project_symbol(project_name)
|
96
|
-
program_name ||= Inochi.calc_program_name(project_symbol)
|
97
|
-
|
98
|
-
project_version = '0.0.0'
|
99
|
-
project_release = Time.now.strftime('%F')
|
100
|
-
|
101
|
-
inochi_preamble = %{
|
102
|
-
require 'rubygems'
|
103
|
-
gem '#{Inochi::PROGRAM}', '#{Inochi::VERSION.requirement}'
|
104
|
-
require '#{Inochi::PROGRAM}'
|
105
|
-
}.strip
|
106
|
-
|
107
|
-
create "#{program_name}/CREDITS", %{
|
108
|
-
* Contributor name
|
109
|
-
* [Contributor name with hyperlink](http://the.contributor's.url)
|
110
|
-
* Another contributor
|
111
|
-
* Yet another contributor
|
112
|
-
}
|
113
|
-
|
114
|
-
create "#{program_name}/LICENSE", %{
|
115
|
-
(the ISC license)
|
116
|
-
|
117
|
-
Copyright #{Time.now.year} Your Name <your@email.here>
|
118
|
-
|
119
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
120
|
-
purpose with or without fee is hereby granted, provided that the above
|
121
|
-
copyright notice and this permission notice appear in all copies.
|
122
|
-
|
123
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
124
|
-
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
125
|
-
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
126
|
-
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
127
|
-
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
128
|
-
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
129
|
-
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
130
|
-
}
|
131
|
-
|
132
|
-
create "#{program_name}/rakefile", %{
|
133
|
-
#{inochi_preamble}
|
134
|
-
|
135
|
-
Inochi.rake #{project_symbol.inspect} do |gem|
|
136
|
-
# TODO: additional gem configuration.
|
137
|
-
# NOTE: this is completely optional!
|
138
|
-
#
|
139
|
-
# gem.extensions = ['foo.so']
|
140
|
-
# gem.files += ['other', 'files']
|
141
|
-
end
|
142
|
-
}
|
143
|
-
|
144
|
-
bin_file = "#{program_name}/bin/#{program_name}"
|
145
|
-
create bin_file, %{
|
146
|
-
#!/usr/bin/env ruby
|
147
|
-
#
|
148
|
-
# TODO: Explain the command-line usage of this program here.
|
149
|
-
#
|
150
|
-
#
|
151
|
-
# Usage:
|
152
|
-
#
|
153
|
-
# #{program_name} [Options] Param1 Param2 Param3...
|
154
|
-
#
|
155
|
-
#
|
156
|
-
# Param1: Description for the first parameter.
|
157
|
-
#
|
158
|
-
# Param2: Description for the second parameter.
|
159
|
-
#
|
160
|
-
# Param3: Description for the third parameter.
|
161
|
-
#
|
162
|
-
#
|
163
|
-
# Options:
|
164
|
-
#
|
165
|
-
|
166
|
-
#{inochi_preamble}
|
167
|
-
|
168
|
-
options = Inochi.main #{project_symbol.inspect} do
|
169
|
-
# TODO: define command-line options here.
|
170
|
-
# see http://trollop.rubyforge.org/
|
171
|
-
#
|
172
|
-
# NOTE: this is completely optional!
|
173
|
-
end
|
174
|
-
|
175
|
-
# TODO: add the body of your program here
|
176
|
-
|
177
|
-
puts "Command-line options: \#{options.inspect}"
|
178
|
-
puts "Command-line arguments: \#{ARGV.inspect}"
|
179
|
-
}
|
180
|
-
FileUtils.chmod 0755, bin_file
|
181
|
-
|
182
|
-
create "#{program_name}/lib/#{program_name}.rb", %{
|
183
|
-
#{inochi_preamble}
|
184
|
-
|
185
|
-
Inochi.init #{project_symbol.inspect},
|
186
|
-
:project => '#{project_name}',
|
187
|
-
:version => '#{project_version}',
|
188
|
-
:release => '#{project_release}',
|
189
|
-
:website => 'http://#{program_name}.rubyforge.org',
|
190
|
-
:tagline => 'put a single line description of your project here',
|
191
|
-
:require => {
|
192
|
-
# TODO: list gems required by your project during runtime here.
|
193
|
-
# NOTE: this is completely optional!
|
194
|
-
#
|
195
|
-
# example: if your project needs version 9.9.9 of the 'foo' gem:
|
196
|
-
# 'foo' => '9.9.9',
|
197
|
-
#
|
198
|
-
# example: if any version of a gem is acceptable then:
|
199
|
-
# 'foo' => nil,
|
200
|
-
},
|
201
|
-
:develop => {
|
202
|
-
# TODO: list gems required by your project during development here.
|
203
|
-
# NOTE: this is completely optional!
|
204
|
-
#
|
205
|
-
# example: if your project needs version 9.9.9 of the 'foo' gem:
|
206
|
-
# 'foo' => '9.9.9',
|
207
|
-
#
|
208
|
-
# example: if any version of a gem is acceptable then:
|
209
|
-
# 'foo' => nil,
|
210
|
-
}
|
211
|
-
}
|
212
|
-
|
213
|
-
create "#{program_name}/test/#{program_name}.rb", %{
|
214
|
-
unless #{project_symbol}.const_defined? :INOCHI
|
215
|
-
fail "#{project_symbol} must be established by Inochi"
|
216
|
-
end
|
217
|
-
|
218
|
-
#{project_symbol}::INOCHI.each do |param, value|
|
219
|
-
const = param.to_s.upcase
|
220
|
-
|
221
|
-
unless #{project_symbol}.const_defined? const
|
222
|
-
fail "#{project_symbol}::\#{const} must be established by Inochi"
|
223
|
-
end
|
224
|
-
|
225
|
-
unless #{project_symbol}.const_get(const) == value
|
226
|
-
fail "#{project_symbol}::\#{const} is not what Inochi established"
|
227
|
-
end
|
228
|
-
end
|
229
|
-
|
230
|
-
puts "Inochi establishment tests passed!"
|
231
|
-
}
|
232
|
-
|
233
|
-
create "#{program_name}/doc/index.erb", %{
|
234
|
-
|
235
|
-
% Inochi.book #{project_symbol.inspect}, self
|
236
|
-
|
237
|
-
%+ "intro.erb"
|
238
|
-
%+ "setup.erb"
|
239
|
-
%+ "theory.erb"
|
240
|
-
%+ "usage.erb"
|
241
|
-
%+ "history.erb"
|
242
|
-
|
243
|
-
}
|
244
|
-
|
245
|
-
create "#{program_name}/doc/intro.erb", %{
|
246
|
-
|
247
|
-
% api_url = './api/index.html'
|
248
|
-
% src_url = "http://github.com/__________/\#{$program}"
|
249
|
-
% src_scm = '[Git](http://git-scm.com)'
|
250
|
-
|
251
|
-
|
252
|
-
%|chapter "Introduction"
|
253
|
-
|
254
|
-
|
255
|
-
%|project
|
256
|
-
|
257
|
-
> TODO: explain the purpose of your project
|
258
|
-
|
259
|
-
<%= $project %> is a __________ that __________.
|
260
|
-
|
261
|
-
|
262
|
-
* <%= xref "History", "What's new?" %> --- history of project releases.
|
263
|
-
* [Source code](<%= src_url %>) --- obtain via <%= src_scm %> or browse online.
|
264
|
-
* [API reference](<%= api_url %>) --- documentation for source code.
|
265
|
-
* [Project home](<%= $website %>) --- the <%= $project %> project home page.
|
266
|
-
|
267
|
-
To get help or provide feedback, simply
|
268
|
-
%= xref "License", "contact the author(s)."
|
269
|
-
|
270
|
-
|
271
|
-
%|section "Features"
|
272
|
-
|
273
|
-
> TODO: explain why your project is important
|
274
|
-
|
275
|
-
<%= $project %> is exciting because:
|
276
|
-
* It lets you __________.
|
277
|
-
* Its core contains less than __________ lines of code.
|
278
|
-
* It __________.
|
279
|
-
|
280
|
-
|
281
|
-
%|section "Etymology"
|
282
|
-
|
283
|
-
> TODO: explain the meaning of the name of your project
|
284
|
-
|
285
|
-
|
286
|
-
%|section "License"
|
287
|
-
|
288
|
-
%< "../LICENSE"
|
289
|
-
|
290
|
-
|
291
|
-
%|section "Credits"
|
292
|
-
|
293
|
-
> TODO: give attribution to your predecessors and contributors
|
294
|
-
|
295
|
-
%= $project
|
296
|
-
is made possible by
|
297
|
-
%= xref "History", "contributions"
|
298
|
-
from users like you:
|
299
|
-
|
300
|
-
%< "../CREDITS"
|
301
|
-
|
302
|
-
|
303
|
-
%|section "Related works"
|
304
|
-
|
305
|
-
> TODO: list other projects which are similar to yours
|
306
|
-
|
307
|
-
* [project 1](http://)
|
308
|
-
* [project 2](http://)
|
309
|
-
* [project 3](http://)
|
310
|
-
|
311
|
-
}
|
312
|
-
|
313
|
-
create "#{program_name}/doc/setup.erb", %{
|
314
|
-
|
315
|
-
%|chapter "Setup"
|
316
|
-
|
317
|
-
|
318
|
-
%|section "Requirements"
|
319
|
-
|
320
|
-
Your system needs the following software to run <%= $project %>.
|
321
|
-
|
322
|
-
| Software | Description | Notes |
|
323
|
-
| -------- | ----------- | ----- |
|
324
|
-
| [Ruby](http://ruby-lang.org) | Ruby language interpreter | Version #{RUBY_VERSION} has been tested successfully. |
|
325
|
-
| [RubyGems](http://rubygems.org) | Ruby packaging system | Version #{Gem::RubyGemsVersion} or newer is required. |
|
326
|
-
|
327
|
-
|
328
|
-
%|section "Installation"
|
329
|
-
|
330
|
-
You can install <%= $project %> by running this command:
|
331
|
-
|
332
|
-
gem install <%= $program %>
|
333
|
-
|
334
|
-
To check whether the installation was sucessful, run this command:
|
335
|
-
|
336
|
-
<%= $program %> --version
|
337
|
-
|
338
|
-
If the installation was successful, you will see output like this:
|
339
|
-
|
340
|
-
<pre><%= verbatim `ruby bin/\#{$program} --version` %></pre>
|
341
|
-
|
342
|
-
If you do not see such output, you may
|
343
|
-
%= xref "License", "ask the author(s)"
|
344
|
-
for help.
|
345
|
-
|
346
|
-
|
347
|
-
%|section "Package contents"
|
348
|
-
|
349
|
-
You will see the following items inside <%= $project %>'s installation
|
350
|
-
directory, whose path you can determine by running this command:
|
351
|
-
|
352
|
-
<%= $program %> --version
|
353
|
-
|
354
|
-
> TODO: list important files your project provides here
|
355
|
-
|
356
|
-
* <tt>bin/</tt>
|
357
|
-
|
358
|
-
* <tt><%= $program %></tt> --- the main <%= $project %> executable.
|
359
|
-
|
360
|
-
* <tt>lib/</tt>
|
361
|
-
|
362
|
-
* <tt><%= $program %>.rb</tt> --- the main <%= $project %> library.
|
363
|
-
|
364
|
-
* <tt><%= $program %>/</tt>
|
365
|
-
|
366
|
-
> TODO: list sub-libraries your project provides here
|
367
|
-
|
368
|
-
* <tt>doc/</tt>
|
369
|
-
|
370
|
-
* <tt>api/</tt> --- API reference documentation.
|
371
|
-
|
372
|
-
* <tt>index.erb</tt> --- source of this user manual.
|
373
|
-
|
374
|
-
* <tt>lang/</tt> --- translations of language phrases.
|
375
|
-
|
376
|
-
* <tt>LICENSE</tt> --- copyright notice and legal conditions.
|
377
|
-
|
378
|
-
* <tt>CREDITS</tt> --- attribution of project contributors.
|
379
|
-
|
380
|
-
|
381
|
-
%|section "Version numbers"
|
382
|
-
|
383
|
-
<%= $project %> releases are numbered in *major.minor.patch*
|
384
|
-
form according to the [RubyGems rational versioning
|
385
|
-
policy](http://www.rubygems.org/read/chapter/7), which
|
386
|
-
can be summarized as follows:
|
387
|
-
|
388
|
-
<table markdown="1">
|
389
|
-
<thead>
|
390
|
-
<tr>
|
391
|
-
<td rowspan="2">What increased in the version number?</td>
|
392
|
-
<td colspan="3">The increase indicates that the release:</td>
|
393
|
-
</tr>
|
394
|
-
<tr>
|
395
|
-
<th>Is backward compatible?</th>
|
396
|
-
<th>Has new features?</th>
|
397
|
-
<th>Has bug fixes?</th>
|
398
|
-
</tr>
|
399
|
-
</thead>
|
400
|
-
<tbody>
|
401
|
-
<tr>
|
402
|
-
<th>major</th>
|
403
|
-
<td style="background-color: #FFE4E1;">No</td>
|
404
|
-
<td>Yes</td>
|
405
|
-
<td>Yes</td>
|
406
|
-
</tr>
|
407
|
-
<tr>
|
408
|
-
<th>minor</th>
|
409
|
-
<td>Yes</td>
|
410
|
-
<td>Yes</td>
|
411
|
-
<td>Yes</td>
|
412
|
-
</tr>
|
413
|
-
<tr>
|
414
|
-
<th>patch</th>
|
415
|
-
<td>Yes</td>
|
416
|
-
<td style="background-color: #FFE4E1;">No</td>
|
417
|
-
<td>Yes</td>
|
418
|
-
</tr>
|
419
|
-
</tbody>
|
420
|
-
</table>
|
421
|
-
|
422
|
-
}
|
423
|
-
|
424
|
-
create "#{program_name}/doc/theory.erb", %{
|
425
|
-
|
426
|
-
%|chapter "Theory of operation"
|
427
|
-
|
428
|
-
> TODO: explain how your project does what it does
|
429
|
-
}
|
430
|
-
|
431
|
-
create "#{program_name}/doc/usage.erb", %{
|
432
|
-
|
433
|
-
%|chapter "Usage"
|
434
|
-
|
435
|
-
|
436
|
-
%|section "Command-line interface"
|
437
|
-
|
438
|
-
When you run this command:
|
439
|
-
|
440
|
-
<%= $program %> --help
|
441
|
-
|
442
|
-
You will see this output:
|
443
|
-
|
444
|
-
<pre><%= verbatim `ruby bin/\#{$program} --help` %></pre>
|
445
|
-
|
446
|
-
> TODO: explain the command-line arguments
|
447
|
-
|
448
|
-
|
449
|
-
%|section "Ruby library interface"
|
450
|
-
|
451
|
-
> TODO: explain how to use your project's Ruby library
|
452
|
-
> from inside another Ruby program or library
|
453
|
-
|
454
|
-
|
455
|
-
%|section "General walkthrough"
|
456
|
-
|
457
|
-
This tutorial walks you through the typical usage of <%= $project %>.
|
458
|
-
|
459
|
-
> TODO: give examples for doing common tasks
|
460
|
-
|
461
|
-
|
462
|
-
%|section "Specific topics"
|
463
|
-
|
464
|
-
> TODO: explain how to do more advanced / specific things
|
465
|
-
|
466
|
-
}
|
467
|
-
|
468
|
-
create "#{program_name}/doc/history.erb", %{
|
469
|
-
|
470
|
-
%|chapter "History"
|
471
|
-
|
472
|
-
> TODO: put a brief history about your project here
|
473
|
-
|
474
|
-
|
475
|
-
%|history
|
476
|
-
|
477
|
-
> TODO: put release notes for your project
|
478
|
-
> here -- newest first, oldest last.
|
479
|
-
|
480
|
-
|
481
|
-
%|section "Version #{project_version} (#{project_release})"
|
482
|
-
|
483
|
-
> TODO: write a short summary of the changes in this release
|
484
|
-
|
485
|
-
This release changes __________, adds __________, and fixes __________.
|
486
|
-
|
487
|
-
|
488
|
-
%|paragraph "Thank you"
|
489
|
-
|
490
|
-
> TODO: list everyone who contributed to this release
|
491
|
-
|
492
|
-
* __________ contributed __________
|
493
|
-
|
494
|
-
* __________ suggested __________
|
495
|
-
|
496
|
-
* __________ helped to __________
|
497
|
-
|
498
|
-
|
499
|
-
%|paragraph "Incompatible changes"
|
500
|
-
|
501
|
-
> TODO: list all backward-incompatible changes in this release
|
502
|
-
|
503
|
-
* __________ has been __________ to __________ ---contributor name
|
504
|
-
|
505
|
-
* __________ ---contributor name
|
506
|
-
|
507
|
-
* __________ ---contributor name
|
508
|
-
|
509
|
-
|
510
|
-
%|paragraph "New features"
|
511
|
-
|
512
|
-
> TODO: list new features added in this release
|
513
|
-
|
514
|
-
* __________ ---contributor name
|
515
|
-
|
516
|
-
* __________ ---contributor name
|
517
|
-
|
518
|
-
* __________ ---contributor name
|
519
|
-
|
520
|
-
|
521
|
-
%|paragraph "Bug fixes"
|
522
|
-
|
523
|
-
> TODO: describe all bugs that are fixed in this release
|
524
|
-
|
525
|
-
* __________ was __________ ---contributor name
|
526
|
-
|
527
|
-
* __________ were __________ ---contributor name
|
528
|
-
|
529
|
-
* __________ did __________ ---contributor name
|
530
|
-
|
531
|
-
|
532
|
-
%|paragraph "Housekeeping"
|
533
|
-
|
534
|
-
> TODO: list the refactorings, clean ups, and other
|
535
|
-
> improvements that were done for this release
|
536
|
-
|
537
|
-
* __________ ---contributor name
|
538
|
-
|
539
|
-
* __________ ---contributor name
|
540
|
-
|
541
|
-
* __________ ---contributor name
|
542
|
-
|
543
|
-
}
|
16
|
+
exit
|
17
|
+
elsif ARGV.delete('-v') or ARGV.delete('--version')
|
18
|
+
puts Inochi::VERSION
|
19
|
+
exit
|
20
|
+
end
|
21
|
+
|
22
|
+
require 'inochi/engine'
|
23
|
+
Inochi::Engine.new.run
|