るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.070秒)

別のキーワード

  1. _builtin grep
  2. _builtin grep_v
  3. enumerable grep
  4. enumerable grep_v
  5. lazy grep

ライブラリ

モジュール

検索結果

FileUtils#sh(*cmd) {|result, status| ... } (18126.0)

与えられたコマンドを実行します。

...@param cmd 引数の解釈に関しては Kernel.#exec を参照してください。


例:
sh
%{ls -ltr}

sh
'ls', 'file with spaces'

# check exit status after command runs
sh
%{grep pattern file} do |ok, res|
if ! ok
puts "pattern not found (status = #{res.exitsta...