Class: Git::CleanRemote::Cleaner
- Inherits:
-
Thor::Shell::Color
- Object
- Thor::Shell::Color
- Git::CleanRemote::Cleaner
- Defined in:
- lib/git-cleanremote/cleaner.rb
Instance Attribute Summary collapse
-
#branch ⇒ Object
readonly
Returns the value of attribute branch.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
-
#remote ⇒ Object
readonly
Returns the value of attribute remote.
Instance Method Summary collapse
-
#initialize(branch, options = {}) ⇒ Cleaner
constructor
A new instance of Cleaner.
Constructor Details
#initialize(branch, options = {}) ⇒ Cleaner
Returns a new instance of Cleaner.
5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/git-cleanremote/cleaner.rb', line 5 def initialize(branch, ={}) @padding = 0 return say ["git-cleanremote", Git::CleanRemoteVersion::STRING].join(' ') if [:version] = .dup @branch = branch @remote = .delete :remote @options = if [:dryrun] dryrun else run end end |
Instance Attribute Details
#branch ⇒ Object (readonly)
Returns the value of attribute branch.
3 4 5 |
# File 'lib/git-cleanremote/cleaner.rb', line 3 def branch @branch end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
3 4 5 |
# File 'lib/git-cleanremote/cleaner.rb', line 3 def @options end |
#remote ⇒ Object (readonly)
Returns the value of attribute remote.
3 4 5 |
# File 'lib/git-cleanremote/cleaner.rb', line 3 def remote @remote end |