Sha256: 6e9dbabe717b18962b9455d606985e9cf37ccb235c22aaf3338dc5461c2104ec

Contents?: true

Size: 716 Bytes

Versions: 20

Compression:

Stored size: 716 Bytes

Contents

# frozen_string_literal: true

# Set the 'from' and 'to' branches, which is used to compile catalogs. A branch of '.' means to use
# the current contents of the base code directory without any git checkouts.
# @param parser [OptionParser object] The OptionParser argument
# @param options [Hash] Options hash being constructed; this is modified in this method.
OctocatalogDiff::Cli::Options::Option.newoption(:to_from_branch) do
  has_weight 20

  def parse(parser, options)
    parser.on('--from FROM_BRANCH', '-f', 'Branch you are coming from') do |env|
      options[:from_env] = env
    end
    parser.on('--to TO_BRANCH', '-t', 'Branch you are going to') do |env|
      options[:to_env] = env
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
octocatalog-diff-2.3.1 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-2.3.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-2.1.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-2.0.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.6.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.5.4 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.5.3 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.5.2 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.5.1 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.5.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.4.1 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.4.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.3.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.2.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.1.0 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.0.4 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.0.3 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.0.2 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.0.1 lib/octocatalog-diff/cli/options/to_from_branch.rb
octocatalog-diff-1.0.0 lib/octocatalog-diff/cli/options/to_from_branch.rb