Skip to content

Instantly share code, notes, and snippets.

@pobo380
Created March 2, 2012 09:04
Show Gist options
  • Save pobo380/1957022 to your computer and use it in GitHub Desktop.
Save pobo380/1957022 to your computer and use it in GitHub Desktop.
# read file from exerb archive
if defined?(ExerbRuntime)
class << File
alias :old_read_for_exerb_archive_filter :read
def read(path, length = nil, offset = 0)
begin
ExerbRuntime.open(path).read(length)
rescue LoadError
old_read_for_exerb_archive_filter(path)
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment