12件ヒット
[1-12件を表示]
(0.019秒)
モジュール
- FileUtils (12)
検索結果
-
FileUtils
# sh(*cmd) {|result , status| . . . } (27.0) -
与えられたコマンドを実行します。
...は 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.exitstatus})"
end
end
@see Kernel.#exe......c, Kernel.#system...