12件ヒット
[1-12件を表示]
(0.042秒)
別のキーワード
ライブラリ
- rake (12)
検索結果
-
FileUtils
# sh(*cmd) {|result , status| . . . } (20.0) -
与えられたコマンドを実行します。
...たコマンドを実行します。
与えられた引数が複数の場合、シェルを経由しないでコマンドを実行します。
@param cmd 引数の解釈に関しては Kernel.#exec を参照してください。
例:
sh %{ls -ltr}
sh 'ls', 'file with spaces'
# c......heck exit status after command runs
sh %{grep pattern file} do |ok, res|
if ! ok
puts "pattern not found (status = #{res.exitstatus})"
end
end
@see Kernel.#exec, Kernel.#system...