Sha256: 78e7735403bc4ef737bf4cc2d8ab97bff79097fc11648584d7e02e51026da190
Contents?: true
Size: 1.45 KB
Versions: 22
Compression:
Stored size: 1.45 KB
Contents
U:RDoc::AnyMethod[iI"sh:EFI"FileUtils#sh;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"PRun the system command +cmd+. If multiple arguments are given the command ;TI"Lis run directly (without the shell, same semantics as Kernel::exec and ;TI"Kernel::system).;To:RDoc::Markup::BlankLine o; ; [I"MIt is recommended you use the multiple argument form over interpolating ;TI"Luser input for both usability and security reasons. With the multiple ;TI"Kargument form you can easily process files with spaces or other shell ;TI"Mreserved characters in them. With the multiple argument form your rake ;TI"Btasks are not vulnerable to users providing an argument like ;TI"<code>; rm # -rf /</code>.;T@o; ; [I"NIf a block is given, upon command completion the block is called with an ;TI"HOK flag (true on a zero exit status) and a Process::Status object. ;TI"NWithout a block a RuntimeError is raised when the command exits non-zero.;T@o; ; [I"Examples:;T@o:RDoc::Markup::Verbatim; [I"sh 'ls -ltr' ;TI" ;TI"!sh 'ls', 'file with spaces' ;TI" ;TI",# check exit status after command runs ;TI"*sh %{grep pattern file} do |ok, res| ;TI" if ! ok ;TI"? puts "pattern not found (status = #{res.exitstatus})" ;TI" end ;TI"end;T:@format0: @fileI"lib/rake/file_utils.rb;T:0@omit_headings_from_table_of_contents_below000[ I"(*cmd, &block);T@-FI"FileUtils;FcRDoc::NormalModule00
Version data entries
22 entries across 22 versions & 2 rubygems