Class: BuildTool::VCS::GitConfiguration
Instance Attribute Summary collapse
#module
Instance Method Summary
collapse
#local_path, #remote_path, #repository
Constructor Details
Returns a new instance of GitConfiguration.
16
17
18
19
|
# File 'lib/build-tool/vcs/git.rb', line 16
def initialize
super
@remote = {}
end
|
Instance Attribute Details
#remote ⇒ Object
Returns the value of attribute remote.
14
15
16
|
# File 'lib/build-tool/vcs/git.rb', line 14
def remote
@remote
end
|
Instance Method Details
#copy_configuration(other) ⇒ Object
43
44
45
46
|
# File 'lib/build-tool/vcs/git.rb', line 43
def copy_configuration( other )
super
@remote = {} end
|
#name ⇒ Object
10
11
12
|
# File 'lib/build-tool/vcs/git.rb', line 10
def name
"git"
end
|
#track_branch ⇒ Object
35
36
37
38
39
40
41
|
# File 'lib/build-tool/vcs/git.rb', line 35
def track_branch
rc = self.module.remote_path.split('/')
return rc[0] if rc.length == 1
return rc[1..-1].join( '/' )
end
|
#track_remote ⇒ Object
27
28
29
30
31
32
33
|
# File 'lib/build-tool/vcs/git.rb', line 27
def track_remote
rc = self.module.remote_path.split('/')
return "origin" if rc.length == 1
return rc[0]
end
|
#vcs(mod) ⇒ Object
21
22
23
24
25
|
# File 'lib/build-tool/vcs/git.rb', line 21
def vcs( mod )
raise StandardError if @module and ! mod.equal?( @module )
@module = mod
Git.new( self )
end
|