Class: Command::Fetch
- Includes:
- FastForward, ReceiveObjects, RemoteClient
- Defined in:
- lib/command/fetch.rb
Constant Summary collapse
- CAPABILITIES =
["ofs-delta"]
- UPLOAD_PACK =
"git-upload-pack"
Constants included from RemoteClient
RemoteClient::REF_LINE, RemoteClient::ZERO_OID
Constants included from ReceiveObjects
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods included from RemoteClient
#build_agent_command, #recv_references, #report_range_update, #report_ref_update, #show_ref_update, #ssh_command, #start_agent
Methods included from ReceiveObjects
#recv_packed_objects, #select_processor_class, #transfer_unpack_limit
Methods included from FastForward
#fast_forward?, #fast_forward_error
Methods inherited from Base
Constructor Details
This class inherits a constructor from Command::Base
Instance Method Details
#define_options ⇒ Object
20 21 22 23 24 25 26 |
# File 'lib/command/fetch.rb', line 20 def @parser.on("-f", "--force") { @options[:force] = true } @parser.on "--upload-pack=<upload-pack>" do |uploader| @options[:uploader] = uploader end end |
#run ⇒ Object
28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/command/fetch.rb', line 28 def run configure start_agent("fetch", @uploader, @fetch_url, CAPABILITIES) recv_references send_want_list send_have_list recv_objects update_remote_refs exit (@errors.empty? ? 0 : 1) end |