Sha256: 17ae207ff97e9fefcd138d75471f84bcf546e47dfa03c2f07f04f148b63e33cc

Contents?: true

Size: 482 Bytes

Versions: 1

Compression:

Stored size: 482 Bytes

Contents

require 'git-utils/command'

class PushBranch < Command

  def parser
    OptionParser.new do |opts|
      opts.banner = "Usage: git push-branch"
      opts.on_tail("-h", "--help", "this usage guide") do
        puts opts.to_s; exit 0
      end
    end
  end

  # Returns a command appropriate for executing at the command line
  def cmd
    c  = ["git push origin #{current_branch}"]
    c += argument_string(unknown_options) unless unknown_options.empty?
    c.join(" ")
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
git-utils-0.5.5 lib/git-utils/push_branch.rb