Sha256: eb6e1d8c53f4e66d26957ed18257f1321a68b05ffb0adf61e3999d6aab890bc7

Contents?: true

Size: 802 Bytes

Versions: 3

Compression:

Stored size: 802 Bytes

Contents

# frozen_string_literal: true

require 'eac_cli/core_ext'
require 'eac_ruby_utils/console/docopt_runner'
require 'ehbrs_ruby_utils/videos/container/file'
require 'eac_ruby_utils/yaml'

module Ehbrs
  class Runner < ::EacRubyUtils::Console::DocoptRunner
    class Videos < ::EacRubyUtils::Console::DocoptRunner
      class Probe
        runner_with :output_file

        runner_definition do
          desc 'FFProbe em um arquivo de vĂ­deo.'
          pos_arg :file_path
        end

        def run
          run_output
        end

        def output_content
          ::EacRubyUtils::Yaml.dump(container_file.info.to_h)
        end

        private

        def container_file_uncached
          ::EhbrsRubyUtils::Videos::Container::File.new(parsed.file_path)
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
ehbrs-tools-0.15.0 lib/ehbrs/runner/videos/probe.rb
ehbrs-tools-0.14.1 lib/ehbrs/runner/videos/probe.rb
ehbrs-tools-0.14.0 lib/ehbrs/runner/videos/probe.rb