Sha256: 1b63ea219331491e585c766358452b3473abb53b288a996e4931afa9ee42c4d8

Contents?: true

Size: 455 Bytes

Versions: 12

Compression:

Stored size: 455 Bytes

Contents

require 'fast_gettext/mo_file'
module FastGettext
  # Responsibility:
  #  - abstract po files for Po Repository
  # TODO refactor...
  class PoFile
    def self.to_mo_file(file, options={})
      require 'fast_gettext/vendor/poparser'
      mo_file = FastGettext::GetText::MOFile.new
      FastGettext::GetText::PoParser.new.parse(File.read(file), mo_file, !options[:ignore_fuzzy], !options[:ignore_obsolete])
      MoFile.new(mo_file)
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
fast_gettext-0.6.7 lib/fast_gettext/po_file.rb
fast_gettext-0.6.6 lib/fast_gettext/po_file.rb
fast_gettext-0.6.5 lib/fast_gettext/po_file.rb
fast_gettext-0.6.4 lib/fast_gettext/po_file.rb
fast_gettext-0.6.3 lib/fast_gettext/po_file.rb
fast_gettext-0.6.2 lib/fast_gettext/po_file.rb
fast_gettext-0.6.1 lib/fast_gettext/po_file.rb
fast_gettext-0.6.0 lib/fast_gettext/po_file.rb
fast_gettext-0.5.13 lib/fast_gettext/po_file.rb
fast_gettext-0.5.12 lib/fast_gettext/po_file.rb
fast_gettext-0.5.11 lib/fast_gettext/po_file.rb
fast_gettext-0.5.10 lib/fast_gettext/po_file.rb