Class: Array
- Inherits:
-
Object
- Object
- Array
- Includes:
- Rush::Commands, Rush::FindBy, Rush::HeadTail
- Defined in:
- lib/rush/array_ext.rb
Overview
Rush mixes in Rush::Commands in order to allow operations on groups of Rush::Entry items. For example, dir[‘*/.rb’] returns an array of files, so dir[‘*/.rb’].destroy would destroy all the files specified.
One cool tidbit: the array can contain entries anywhere, so you can create collections of entries from different servers and then operate across them:
[ box1['/var/log/access.log'] + box2['/var/log/access.log'] ].search /#{url}/
Instance Method Summary collapse
Methods included from Rush::HeadTail
Methods included from Rush::FindBy
#compare_or_match, #find_all_by, #find_by, #method_missing
Methods included from Rush::Commands
#line_count, #replace_contents!, #search
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Rush::FindBy
Instance Method Details
#entries ⇒ Object
12 13 14 |
# File 'lib/rush/array_ext.rb', line 12 def entries self end |