Add a command line parsing procedure
This commit is contained in:
10
Rakefile
10
Rakefile
@ -44,10 +44,12 @@ end
|
||||
.partition { |f| f.end_with? '.elna' }
|
||||
|
||||
File.open t.name, 'w' do |output|
|
||||
puts
|
||||
puts(compiler * ' ')
|
||||
compiler_command = compiler + sources
|
||||
|
||||
Open3.popen2(*compiler) do |cl_in, cl_out|
|
||||
puts
|
||||
puts(compiler_command * ' ')
|
||||
|
||||
Open3.popen2(*compiler_command) do |cl_in, cl_out|
|
||||
cl_in.write File.read(*sources)
|
||||
cl_in.close
|
||||
|
||||
@ -104,7 +106,7 @@ task :backport do
|
||||
source
|
||||
.gsub(/^(var|type|const|begin)/) { |match| match.upcase }
|
||||
.gsub(/^[[:alnum:]]* ?module/) { |match| match.upcase }
|
||||
.gsub(/\b(record|nil|or)\b/) { |match| match.upcase }
|
||||
.gsub(/\b(record|nil|or|false|true)\b/) { |match| match.upcase }
|
||||
.gsub(/proc\(/, 'PROCEDURE(')
|
||||
.gsub(/ & /, ' AND ')
|
||||
.gsub(/ -> /, ': ')
|
||||
|
Reference in New Issue
Block a user