Permalink
Browse files

Cleanup iscc.exe command line args generation.

  • Loading branch information...
1 parent 51657a9 commit b077dd6d7c7ed187cf0c1ba876bc734b800aaddc @jonforums jonforums committed Jul 26, 2010
Showing with 7 additions and 3 deletions.
  1. +7 −3 recipes/packager/inno.rake
@@ -24,15 +24,19 @@ module InnoSetup
false
end
+ # TODO: refactor to convert options hash to /d{hash_key}={hash_value}
+ # unless {hash_key} == :output || :filename
+ # TODO: borrow some proven snake_case -> CamelCase code for converting
+ # the hash keys to /d args
def self.iscc(script, *args)
cmd = []
options = args.last || {}
cmd << EXECUTABLE
cmd << script
- cmd << "/dRubyVersion=#{options[:ruby_version]}"
- cmd << "/dRubyPatch=#{options[:ruby_patch]}"
- cmd << "/dRubyPath=#{options[:ruby_path]}"
+ cmd << "/dRubyVersion=#{options[:ruby_version]}" if options[:ruby_version]
+ cmd << "/dRubyPatch=#{options[:ruby_patch]}" if options[:ruby_patch]
+ cmd << "/dRubyPath=#{options[:ruby_path]}" if options[:ruby_path]
cmd << "/o#{options[:output]}" if options[:output]
cmd << "/f#{options[:filename]}" if options[:filename]
if options[:sign] then

0 comments on commit b077dd6

Please sign in to comment.