Method: Train::Extras::LinuxFile#content
- Defined in:
- lib/train/extras/file_linux.rb
#content ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'lib/train/extras/file_linux.rb', line 7 def content return @content if defined?(@content) @content = @backend.run_command( "cat #{@spath} || echo -n").stdout return @content unless @content.empty? @content = nil if directory? or size.nil? or size > 0 @content end |