Skip to content

Instantly share code, notes, and snippets.

@jcoyne
Created July 24, 2013 18:37
Show Gist options
  • Save jcoyne/6073232 to your computer and use it in GitHub Desktop.
Save jcoyne/6073232 to your computer and use it in GitHub Desktop.
[:ffmpeg_path, :libreoffice_path, :temp_file_base, :fits_path, :enable_ffmpeg].each do |method|
module_eval <<- RUBY
def #{method.to_s}
puts 'hey'
end
RUBY
end
/Users/justin/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:51:in `require': /Users/justin/workspace/hydra-derivatives/lib/hydra/derivatives.rb:26: syntax error, unexpected tSTRING_BEG, expecting ';' or '\n' (SyntaxError)
puts 'hey'
^
/Users/justin/workspace/hydra-derivatives/lib/hydra/derivatives.rb:59: class definition in method body
/Users/justin/workspace/hydra-derivatives/lib/hydra/derivatives.rb:79: module definition in method body
/Users/justin/workspace/hydra-derivatives/lib/hydra/derivatives.rb:100: syntax error, unexpected keyword_end, expecting end-of-input
from /Users/justin/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:51:in `require'
from /Users/justin/workspace/hydra-derivatives/spec/spec_helper.rb:4:in `<top (required)>'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment