Class: Capistrano::Harrow::Config::Git
- Inherits:
-
Object
- Object
- Capistrano::Harrow::Config::Git
- Defined in:
- lib/capistrano/harrow/config/git.rb
Instance Method Summary collapse
- #disabled? ⇒ Boolean
- #email ⇒ Object
-
#initialize(config_file) ⇒ Git
constructor
A new instance of Git.
- #installed? ⇒ Boolean
- #organization_uuid ⇒ Object
- #organization_uuid=(value) ⇒ Object
- #project_uuid ⇒ Object
- #project_uuid=(value) ⇒ Object
- #repository_url ⇒ Object
- #session_uuid ⇒ Object
- #session_uuid=(value) ⇒ Object
- #username ⇒ Object
Constructor Details
#initialize(config_file) ⇒ Git
Returns a new instance of Git.
7 8 9 |
# File 'lib/capistrano/harrow/config/git.rb', line 7 def initialize(config_file) @config_file = config_file end |
Instance Method Details
#disabled? ⇒ Boolean
11 12 13 14 15 16 17 18 |
# File 'lib/capistrano/harrow/config/git.rb', line 11 def disabled? case get :'harrow.disabled' when 'true' then true when 'false' then false else false end end |
#email ⇒ Object
56 57 58 |
# File 'lib/capistrano/harrow/config/git.rb', line 56 def email get :'user.email' end |
#installed? ⇒ Boolean
20 21 22 |
# File 'lib/capistrano/harrow/config/git.rb', line 20 def installed? not session_uuid.to_s.empty? end |
#organization_uuid ⇒ Object
36 37 38 |
# File 'lib/capistrano/harrow/config/git.rb', line 36 def organization_uuid get :'harrow.organization.uuid' end |
#organization_uuid=(value) ⇒ Object
32 33 34 |
# File 'lib/capistrano/harrow/config/git.rb', line 32 def organization_uuid=(value) set :'harrow.organization.uuid', value end |
#project_uuid ⇒ Object
44 45 46 |
# File 'lib/capistrano/harrow/config/git.rb', line 44 def project_uuid get :'harrow.organization.uuid' end |
#project_uuid=(value) ⇒ Object
40 41 42 |
# File 'lib/capistrano/harrow/config/git.rb', line 40 def project_uuid=(value) set :'harrow.project.uuid', value end |
#repository_url ⇒ Object
48 49 50 |
# File 'lib/capistrano/harrow/config/git.rb', line 48 def repository_url get :'remote.origin.url' end |
#session_uuid ⇒ Object
28 29 30 |
# File 'lib/capistrano/harrow/config/git.rb', line 28 def session_uuid get :'harrow.session.uuid' end |
#session_uuid=(value) ⇒ Object
24 25 26 |
# File 'lib/capistrano/harrow/config/git.rb', line 24 def session_uuid=(value) set :'harrow.session.uuid', value end |
#username ⇒ Object
52 53 54 |
# File 'lib/capistrano/harrow/config/git.rb', line 52 def username get :'user.name' end |