Class: DYAutomate::Command::Git
- Inherits:
-
DYAutomate::Command
- Object
- CLAide::Command
- DYAutomate::Command
- DYAutomate::Command::Git
- Defined in:
- lib/DYAutomate/Command/dgit.rb,
lib/DYAutomate/Command/Git/tagAdd.rb
Direct Known Subclasses
Defined Under Namespace
Classes: TagAdd
Instance Attribute Summary collapse
-
#git_obj ⇒ Object
#查询结果lib信息.
-
#path ⇒ Object
路径.
Attributes inherited from DYAutomate::Command
Instance Method Summary collapse
- #existGit? ⇒ Boolean
-
#initialize(argv) ⇒ Git
constructor
A new instance of Git.
- #run ⇒ Object
- #validate! ⇒ Object
Methods inherited from DYAutomate::Command
Constructor Details
#initialize(argv) ⇒ Git
Returns a new instance of Git.
22 23 24 |
# File 'lib/DYAutomate/Command/dgit.rb', line 22 def initialize(argv) super end |
Instance Attribute Details
#git_obj ⇒ Object
#查询结果lib信息
20 21 22 |
# File 'lib/DYAutomate/Command/dgit.rb', line 20 def git_obj @git_obj end |
#path ⇒ Object
路径
18 19 20 |
# File 'lib/DYAutomate/Command/dgit.rb', line 18 def path @path end |
Instance Method Details
#existGit? ⇒ Boolean
41 42 43 44 |
# File 'lib/DYAutomate/Command/dgit.rb', line 41 def existGit? @git_obj = Git.new(Dir.pwd) @git_obj end |
#run ⇒ Object
37 38 39 |
# File 'lib/DYAutomate/Command/dgit.rb', line 37 def run pp('git run ...',1) end |
#validate! ⇒ Object
26 27 28 29 30 31 32 33 34 35 |
# File 'lib/DYAutomate/Command/dgit.rb', line 26 def validate! super # unless @name # help! 'need the lib `NAME`.' # end unless existGit? help! "at #{Dir.pwd},is not git" end end |